-
Notifications
You must be signed in to change notification settings - Fork 804
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Detect if we are in onceWrapper #3132
Conversation
Codecov Report
@@ Coverage Diff @@
## main #3132 +/- ##
==========================================
- Coverage 93.10% 92.71% -0.40%
==========================================
Files 196 181 -15
Lines 6400 5671 -729
Branches 1349 1204 -145
==========================================
- Hits 5959 5258 -701
+ Misses 441 413 -28
|
context: Context | ||
) { | ||
const contextManager = this; | ||
return function (this: never, event: string, listener: Func<void>) { | ||
let active = contextManager.active(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do you use the active context manager here instead self?
Why do you set a property on context instead within the ContextManager instance?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made a new version already I'm closing this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixes #2971
This is an alternative solution to #3123 and #3122