Skip to content

Commit

Permalink
fix(lifecycle-hooks): only call hooks once
Browse files Browse the repository at this point in the history
  • Loading branch information
Sorikairox committed Oct 13, 2022
1 parent e298ac8 commit 5a664c7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@ export class DanetApplication {
if (metadata.controllers) {
this.danetRouter.registerControllers(metadata.controllers);
}
await this.hookExecutor.executeHookForEveryInjectable(
hookName.APP_BOOTSTRAP,
);
}

async init(Module: Constructor) {
await this.bootstrap(Module);
await this.hookExecutor.executeHookForEveryInjectable(
hookName.APP_BOOTSTRAP,
);
}

async close() {
Expand Down

0 comments on commit 5a664c7

Please sign in to comment.