Skip to content

Commit

Permalink
perf: reduce database operations when using the constant parameter in…
Browse files Browse the repository at this point in the history
… Cloud Function validation (parse-community#7892)
  • Loading branch information
dblythy authored Mar 26, 2022
1 parent b3199d7 commit 48bd512
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/triggers.js
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,7 @@ async function builtInTriggerValidator(options, request, auth) {
}
if (opt.constant && request.object) {
if (request.original) {
request.object.set(key, request.original.get(key));
request.object.revert(key);
} else if (opt.default != null) {
request.object.set(key, opt.default);
}
Expand Down

0 comments on commit 48bd512

Please sign in to comment.