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

UUID as Account.id #905

Merged
merged 8 commits into from
Apr 14, 2019
Merged

UUID as Account.id #905

merged 8 commits into from
Apr 14, 2019

Conversation

lautarodragan
Copy link
Member

@lautarodragan lautarodragan commented Apr 11, 2019

Finishes #919
Progress on #903

Changes

  • installs https://www.npmjs.com/package/uuid
  • introduces new id field for accounts
  • id is a uuid
  • POST /accounts now returns { id, issuer, token }
  • GET /accounts/:issuer now returns id
  • no breaking changes, but we'll need to run a migration to add id to all previous users

TODO

  • uuidToBytes? -> for a future PR, but it's just Buffer.from(uuid.replace(/-/g, ''), 'hex')
  • id: string, transform to/from Buffer at db level? -> need proper arch first, we have no real DAO :(

@lautarodragan lautarodragan marked this pull request as ready for review April 14, 2019 03:56
@lautarodragan lautarodragan merged commit e621573 into master Apr 14, 2019
@lautarodragan lautarodragan deleted the account-uuid branch April 14, 2019 06:27
@poet-ci
Copy link

poet-ci commented Apr 14, 2019

🎉 This PR is included in version 1.28.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

2 participants