Skip to content

Commit

Permalink
fix: only create a new global container if it does not exist
Browse files Browse the repository at this point in the history
  • Loading branch information
jlenon7 committed Feb 8, 2022
1 parent 1c4c692 commit cc94442
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@secjs/ioc",
"version": "1.0.7",
"version": "1.0.8",
"description": "",
"license": "MIT",
"author": "João Lenon",
Expand Down
2 changes: 1 addition & 1 deletion src/utils/global.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ declare global {

const _global = global as any

_global.Container = new Container()
if (!_global.Container) _global.Container = new Container()

0 comments on commit cc94442

Please sign in to comment.