-
-
Save vdeturckheim/a6a5c43b846b11e28eab5d99e4e103b7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function () { | |
runPreHooks(this, arguments); | |
let result; | |
try { | |
if (new.target) { | |
result = Reflect.construct(fn, arguments, new.target); | |
} | |
restult = fn.apply(this, arguments); | |
} | |
catch (err) { | |
runFaillingHooks(this, arguments, err); | |
throw err; | |
} | |
runPostHooks(this, arguments, result); | |
return result; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment