fix: Incorrect policies returned from documents.update (#7111)
* fix: Incorrect policies returned from documents.update * Regression test
This commit is contained in:
@@ -996,7 +996,7 @@ router.post(
|
||||
const { user } = ctx.state.auth;
|
||||
let collection: Collection | null | undefined;
|
||||
|
||||
const document = await Document.findByPk(id, {
|
||||
let document = await Document.findByPk(id, {
|
||||
userId: user.id,
|
||||
includeState: true,
|
||||
transaction,
|
||||
@@ -1037,7 +1037,7 @@ router.post(
|
||||
}
|
||||
}
|
||||
|
||||
await documentUpdater({
|
||||
document = await documentUpdater({
|
||||
document,
|
||||
user,
|
||||
...input,
|
||||
|
||||
Reference in New Issue
Block a user