Skip to content

Commit

Permalink
fix: ensures update field access control receives id
Browse files Browse the repository at this point in the history
  • Loading branch information
JarrodMFlesch committed Oct 4, 2021
1 parent 8d6372e commit ffab6c4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/collections/operations/update.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ async function update(incomingArgs: Arguments): Promise<Document> {
docWithLocales = JSON.parse(docWithLocales);

const originalDoc = await performFieldOperations(collectionConfig, {
id,
depth: 0,
req,
data: docWithLocales,
Expand Down Expand Up @@ -279,6 +280,7 @@ async function update(incomingArgs: Arguments): Promise<Document> {
// /////////////////////////////////////

result = await performFieldOperations(collectionConfig, {
id,
depth,
req,
data: result,
Expand Down

0 comments on commit ffab6c4

Please sign in to comment.