feat: Allow Parse.Object pointers in Cloud Code arguments (#8490)

This commit is contained in:
Daniel
2023-05-26 06:02:33 +10:00
committed by GitHub
parent fd6a0077f2
commit 28aeda3f16
2 changed files with 27 additions and 0 deletions

View File

@@ -18,6 +18,12 @@ function parseObject(obj) {
return Object.assign(new Date(obj.iso), obj);
} else if (obj && obj.__type == 'File') {
return Parse.File.fromJSON(obj);
} else if (obj && obj.__type == 'Pointer') {
return Parse.Object.fromJSON({
__type: 'Pointer',
className: obj.className,
objectId: obj.objectId,
});
} else if (obj && typeof obj === 'object') {
return parseParams(obj);
} else {