Skip to content

Commit 6b65439

Browse files
committed
Run schema validation after beforeSave is run
1 parent 99cfd6a commit 6b65439

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/RestWrite.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,6 @@ RestWrite.prototype.execute = function() {
6262
return this.getUserAndRoleACL();
6363
}).then(() => {
6464
return this.validateClientClassCreation();
65-
}).then(() => {
66-
return this.validateSchema();
6765
}).then(() => {
6866
return this.handleInstallation();
6967
}).then(() => {
@@ -72,6 +70,8 @@ RestWrite.prototype.execute = function() {
7270
return this.validateAuthData();
7371
}).then(() => {
7472
return this.runBeforeTrigger();
73+
}).then(() => {
74+
return this.validateSchema();
7575
}).then(() => {
7676
return this.setRequiredFieldsIfNeeded();
7777
}).then(() => {
@@ -176,7 +176,6 @@ RestWrite.prototype.runBeforeTrigger = function() {
176176
if (this.query && this.query.objectId) {
177177
delete this.data.objectId
178178
}
179-
return this.validateSchema();
180179
}
181180
});
182181
};

0 commit comments

Comments
 (0)