Skip to content

Commit e310078

Browse files
author
Patrick Housley
committed
Controller constructre called twice
- Updated the ActionMetadata `callMethod` method to use the ControllerMetadata `instance` getter once.
1 parent faf0f15 commit e310078

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/metadata/ActionMetadata.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,8 @@ export class ActionMetadata {
257257
* Action method is an action defined in a user controller.
258258
*/
259259
callMethod(params: any[]) {
260-
return this.controllerMetadata.instance[this.method].apply(this.controllerMetadata.instance, params);
260+
const controllerInstance = this.controllerMetadata.instance;
261+
return controllerInstance[this.method].apply(controllerInstance, params);
261262
}
262263

263264
// -------------------------------------------------------------------------

0 commit comments

Comments
 (0)