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

Add a method for directly checking for an update #85

Closed
LinusU opened this issue Jun 10, 2016 · 8 comments
Closed

Add a method for directly checking for an update #85

LinusU opened this issue Jun 10, 2016 · 8 comments
Labels
enhancement 🎁 Rewarded on Issuehunt This issue has been rewarded on Issuehunt help wanted

Comments

@LinusU
Copy link
Contributor

LinusU commented Jun 10, 2016

Issuehunt badges

Having the callback specified as a field in the options object makes this library incompatible with e.g. pify and I think all other promisify-libraries as well. It's also very uncommon in the Node.js community where the callback is usually given as the last parameter.

Would it be possible to update to a form where the callback is given as a second parameter? This could probably be done in a backwards compatible way as well. Possibly printing deprecation warning and then dropping it in the next major version.

Any thoughts?


IssueHunt Summary

litomore litomore has been rewarded.

Backers (Total: $40.00)

Submitted pull Requests


Tips


IssueHunt has been backed by the following sponsors. Become a sponsor

@sindresorhus
Copy link
Member

It's in the options as it's not the main way to use this module. Ideally, it would support promises too. I think that would be a better change.

@sindresorhus
Copy link
Member

Actually, I think we should just deprecate the callback option and add a updateNotifier.check() method that returns a Promise for the update.

@sindresorhus sindresorhus changed the title Callbacks in options object is very uncommon and confusing Add a method for directly checking for an update Feb 13, 2017
@IssueHuntBot
Copy link

@IssueHunt has funded $40.00 to this issue.


@issuehunt-oss issuehunt-oss bot added the 💵 Funded on Issuehunt This issue has been funded on Issuehunt label May 10, 2019
@LitoMore
Copy link
Contributor

I have already solved this issue in the #151.

@LitoMore
Copy link
Contributor

We can use the updateNotifier.checkNpm() to get the version info, and it has already refactored to Promise.

@LitoMore
Copy link
Contributor

LitoMore commented May 16, 2019

I will make a new pull request to deprecate the callback option.

@sindresorhus
Copy link
Member

Fixed by #158

@issuehunt-oss issuehunt-oss bot removed the 💵 Funded on Issuehunt This issue has been funded on Issuehunt label Dec 12, 2019
@issuehunt-oss
Copy link

issuehunt-oss bot commented Dec 12, 2019

@sindresorhus has rewarded $36.00 to @litomore. See it on IssueHunt

  • 💰 Total deposit: $40.00
  • 🎉 Repository reward(0%): $0.00
  • 🔧 Service fee(10%): $4.00

@issuehunt-oss issuehunt-oss bot added the 🎁 Rewarded on Issuehunt This issue has been rewarded on Issuehunt label Dec 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement 🎁 Rewarded on Issuehunt This issue has been rewarded on Issuehunt help wanted
Projects
None yet
Development

No branches or pull requests

4 participants