fix(hooks): incorrect hook executing for field-level afterChange
This commit is contained in:
@@ -183,8 +183,8 @@ async function create(args) {
|
||||
|
||||
result = await performFieldOperations(collectionConfig, {
|
||||
data: result,
|
||||
hook: 'afterRead',
|
||||
operation: 'read',
|
||||
hook: 'afterChange',
|
||||
operation: 'create',
|
||||
req,
|
||||
depth,
|
||||
overrideAccess,
|
||||
|
||||
@@ -223,8 +223,8 @@ async function update(args) {
|
||||
|
||||
doc = await this.performFieldOperations(collectionConfig, {
|
||||
data: doc,
|
||||
hook: 'afterRead',
|
||||
operation: 'read',
|
||||
hook: 'afterChange',
|
||||
operation: 'update',
|
||||
req,
|
||||
id,
|
||||
depth,
|
||||
|
||||
Reference in New Issue
Block a user