Skip to content

Commit 1e14125

Browse files
Merge pull request #180 from NickBolles/njb/add-toJSON-to-models
add toJSON function to models
2 parents ba71770 + c502eca commit 1e14125

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/service-module/model.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,10 @@ export default function (options) {
168168
return this._remove(this[idField], params)
169169
}
170170
_remove () {}
171+
172+
toJSON () {
173+
return fastCopy(this)
174+
}
171175
}
172176

173177
Object.assign(FeathersVuexModel, {

0 commit comments

Comments
 (0)