Skip to content

Commit

Permalink
Fixed promisify bug with scope passing to the original function;
Browse files Browse the repository at this point in the history
  • Loading branch information
DigitalBrainJS committed Apr 21, 2021
1 parent 026c8a1 commit 5d6e32c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/c-promise.js
Original file line number Diff line number Diff line change
Expand Up @@ -1618,7 +1618,7 @@ class CPromise extends Promise {

const result = decoratedFn.apply(
this,
scopeArg ? [scopeArg, ...args, callback] : [...args, callback]
scopeArg ? [scope, ...args, callback] : [...args, callback]
);

if (isThenable(result)) {
Expand Down

0 comments on commit 5d6e32c

Please sign in to comment.