diff --git a/packages/core/src/App.ts b/packages/core/src/App.ts index 648c2aa0..14d17ec6 100644 --- a/packages/core/src/App.ts +++ b/packages/core/src/App.ts @@ -293,9 +293,11 @@ class App extends EventEmitter { const method = methods.find((item) => item.name === methodName); if (method && typeof method.content === 'function') { - await method.content({ app: this, params, dataSource, eventParams: args, flowState, node }); - } else if (typeof dataSource[methodName] === 'function') { - await dataSource[methodName](); + return await method.content({ app: this, params, dataSource, eventParams: args, flowState, node }); + } + + if (typeof dataSource[methodName] === 'function') { + return await dataSource[methodName](); } } catch (e: any) { if (this.errorHandler) {