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

[Idea] synchronous version #3

Open
FedericoCapaldo opened this issue Dec 14, 2017 · 3 comments
Open

[Idea] synchronous version #3

FedericoCapaldo opened this issue Dec 14, 2017 · 3 comments

Comments

@FedericoCapaldo
Copy link

I understood the purpose of making the module asynchronous is not to block the whole app. Though, I am using this package for an academic simulation, where the waiting time is not a concern, and it would be more appropriate for me to use a synchronous version of this. Would a sync version possible to develop?

@almic
Copy link

almic commented Feb 16, 2018

I just copied the code, gutted the Promise stuff, and changed crypto.randomBytesAsync() to crypto.randomBytes(). Here's my version if you or someone else ever needs it: https://gist.github.com/almic/7007eafe54e44839635bfb8ce0b6942e

@DanielRuf
Copy link

Thanks =)

@DanielRuf
Copy link

Can we get this as fork or update in a new release?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants