Skip to content

Commit 220a133

Browse files
author
Francis Lessard
committed
no message
1 parent d7d87a3 commit 220a133

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/RestWrite.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,9 @@ function RestWrite(config, auth, className, query, data, originalData) {
2727
this.auth = auth;
2828
this.className = className;
2929
this.storage = {};
30-
this.runOptions = {};
30+
this.runOptions = {
31+
acl:['*']
32+
};
3133

3234
if (!query && data.objectId) {
3335
throw new Parse.Error(Parse.Error.INVALID_KEY_NAME, 'objectId ' +
@@ -97,9 +99,8 @@ RestWrite.prototype.getUserAndRoleACL = function() {
9799
return Promise.resolve();
98100
}
99101
return this.auth.getUserRoles().then((roles) => {
100-
roles.push('*');
101102
roles.push(this.auth.user.id);
102-
this.runOptions.acl = roles;
103+
this.runOptions.acl = this.runOptions.acl.concat(roles);
103104
return Promise.resolve();
104105
});
105106
};

0 commit comments

Comments
 (0)