Skip to content

Commit

Permalink
Remove 'updateAt' property in leancloud update.
Browse files Browse the repository at this point in the history
  • Loading branch information
orangecheers-x committed Oct 6, 2023
1 parent 672b4d5 commit 062ea2f
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions packages/server/src/service/storage/leancloud.js
Original file line number Diff line number Diff line change
Expand Up @@ -405,11 +405,15 @@ module.exports = class extends Base {
ret.map(async (item) => {
const _oldStatus = item.get('status');

var newData
if (think.isFunction(data)) {
item.set(data(item.toJSON()));
} else {
item.set(data);
newData = data(item.toJSON())
}
if ('updatedAt' in newData) {
delete newData.updatedAt
}
item.set(newData)

const _newStatus = item.get('status');

if (_newStatus && _oldStatus !== _newStatus) {
Expand Down

0 comments on commit 062ea2f

Please sign in to comment.