WatermelonDB icon indicating copy to clipboard operation
WatermelonDB copied to clipboard

this.update throws error -> Error: Invalid argument type for query - only strings, numbers, booleans and null are allowed

Open pulbyte opened this issue 3 years ago • 0 comments

Using this.update inside a @writer

@writer async like() { await this.update((record) => { record.totalLikes = record.totalLikes + 1 }) }

It throws an error back : Error: Invalid argument type for query - only strings, numbers, booleans and null are allowed at batchJSON (native) at apply (native) at call http://localhost:8081/index.bundle?platform=android&dev=true&minify=false&app=com.my.app&modulesOnly=false&runModule=true:131340:34 ...

pulbyte avatar Dec 06 '21 06:12 pulbyte