diff --git a/src/domain/make-relations.js b/src/domain/make-relations.js index 733fc2e6..31305de0 100644 --- a/src/domain/make-relations.js +++ b/src/domain/make-relations.js @@ -126,7 +126,7 @@ export default function makeRelations(relations, datasource, observer) { ...args ); - if (event?.args.length > 0) { + if (event && event.args.length > 0) { await updateForeignKeys(this, event, rel, ds); }