We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 053da6b commit 34b32c3Copy full SHA for 34b32c3
spec/CloudCode.spec.js
@@ -1552,17 +1552,19 @@ describe('Cloud Code', () => {
1552
Parse.Cloud.beforeSave('TestObject', ({ object }) => {
1553
if (!object.existed()) {
1554
object.set('secret', true);
1555
+ return object;
1556
}
1557
+ object.revert('secret');
1558
});
1559
1560
Parse.Cloud.afterSave('TestObject', ({ object }) => {
1561
object.unset('secret');
1562
1563
- Parse.Cloud.afterFind(
1564
+ Parse.Cloud.beforeFind(
1565
'TestObject',
- ({ objects }) => {
- objects.map(object => object.unset('secret'));
1566
+ ({ query }) => {
1567
+ query.exclude('secret');
1568
},
1569
{
1570
skipWithMasterKey: true,
0 commit comments