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

Bug - id length varies randomly toggles between 14 and 15. #25

Open
Sulaiman90 opened this issue Feb 22, 2019 · 4 comments
Open

Bug - id length varies randomly toggles between 14 and 15. #25

Sulaiman90 opened this issue Feb 22, 2019 · 4 comments

Comments

@Sulaiman90
Copy link

When I tested in nodejs and npm testkit in https://npm.runkit.com/uniqid, id length switches between 14 & 15.
Its is not constant.

@sam13591980
Copy link

and for me it is 16 and not 18 based on the document.

@elig0n
Copy link

elig0n commented Jun 2, 2019

Same I'm getting 14 bytes long instead of 18 as documented.
Looks like the documentation is bad because the way it's done in the source mac can have varying number of digits, and pid as well, so one can't infer a constant length for the uniqid.

@waleedsamy
Copy link

same, we get 15 char long (expecting 16)

@Romstar
Copy link

Romstar commented Dec 9, 2020

I've been getting 9 but it's probably because my code is running in a Firebase cloud function.

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

5 participants