Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

use native UUID method if available #1585

Merged
merged 4 commits into from
Oct 18, 2022
Merged

Conversation

xavdid-stripe
Copy link
Member

Fixes #1101 by using the native UUID implementation, if available. Added a (very) basic test as a starter.

@richardm-stripe
Copy link
Contributor

LGTM, I pushed a commit and wrote one of the tests you described

@xavdid-stripe
Copy link
Member Author

@richardm-stripe Ok, I pushed a tweak to your test so we only mock when the function was otherwise available.

Mind giving it a quick review when you have a chance?

@xavdid-stripe xavdid-stripe enabled auto-merge (squash) October 18, 2022 17:15
@xavdid-stripe xavdid-stripe merged commit c9d9522 into master Oct 18, 2022
@xavdid-stripe
Copy link
Member Author

Ope! Turns out auto-merge doesn't wait for reviewers 🤔 Probably still take a peek and lmk if you see anything we should tweak. Thank you!

@xavdid-stripe xavdid-stripe deleted the xavdid/use-native-uuid branch October 18, 2022 17:16
gurus00 pushed a commit to gurus00/stripe-node that referenced this pull request Feb 11, 2025
* use native UUID method if available

Co-authored-by: Richard Marmorstein <richardm@stripe.com>
gurus00 pushed a commit to gurus00/stripe-node that referenced this pull request Feb 11, 2025
* use native UUID method if available

Co-authored-by: Richard Marmorstein <richardm@stripe.com>
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Math.random() is not a cryptographically secure way to generate UUIDv4s
2 participants