Closed gpierrick closed 6 years ago
I notice you're inserting data[0]
but saving data
-- is that correct? Can you provide sample data?
Oops sorry it's meant to be data - also I have just tried insert and that works save doesn't
[{ userId: 1, conversationId: 2, read: true, deleted: false },{ userId: 2, conversationId: 2, read: true, deleted: false }]
The error message you received is consistent with passing an array or thing-other-than-an-object to save
, and that check goes back past 3.1.0. Please provide sample data which triggers the error on save.
I am still using 2.7.2 on my other project that's probably why.
You can only save
one object at a time -- it doesn't handle arrays.
Table userId conversationId read deleted
This works
This doesn't
It used to work in a previous version (I have one API running the old version of massivejs)
Error message
Must provide an object with all fields being modified and the primary key if updating