You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 12, 2024. It is now read-only.
I find myself often preferring to use Promises and more recently await. As per IPFS api functions, we return a Promise (or callback) and I find it confusing that stop() is only callback.
If we returned a Promise, we would write:
ipfs.stop().then(()=>{// do other shutdown things})// Or:awaitipfs.stop()// do other shutdown things
I'd like to propose we promisify the stop function.
We would keep the original callback in addition to returning a Promise, same as we do for API functions and the start() function.
How does everyone feel about this?
I'd be happy to PR this, but this would be a great task for first contributors if someone wants to work on it!