Skip to content
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

Promise.prototype.finally #169

Open
ericman314 opened this issue Jul 29, 2020 · 3 comments · May be fixed by #388
Open

Promise.prototype.finally #169

ericman314 opened this issue Jul 29, 2020 · 3 comments · May be fixed by #388

Comments

@ericman314
Copy link

Promise.prototype.finally() was added in Node v10 and is also in most major browsers now. It would be great to have that function available from pool.exec.

Some references:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/finally
https://github.com/tc39/proposal-promise-finally/blob/fd934c0b42d59bf8d9446e737ba14d50a9067216/polyfill.js

@josdejong
Copy link
Owner

Good idea 👍

Anyone interested in implemented finally?

@adrfantini
Copy link

One thing I noticed is that exec actually returns a promise with an .always() method available. However, it is not documented as far as I can tell.

@josdejong
Copy link
Owner

That can be refactored I think, it's similar to finally

@wmertens wmertens linked a pull request Apr 24, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants