robsontenorio/vue-api-query

save() return results

Closed this issue · 1 comments

Vue api query version.

"vue-api-query": "^1.5.2",

async saveWorkout({ commit }, params) {
      let data = await new Workout(params).save()

      console.log(data)
}

the save() does not return the actual results of the request it always returns the value of the model and plus the data of the request result.

image

I think it is related to ES syntax, not this package. Try:

      let data = await (new Workout(params)).save()