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

feat(user-tokens): user tokens api #428

Merged
merged 11 commits into from
Mar 30, 2022
Merged

feat(user-tokens): user tokens api #428

merged 11 commits into from
Mar 30, 2022

Conversation

samuelmasse
Copy link
Contributor

@samuelmasse samuelmasse commented Mar 28, 2022

Adds API routes to create user tokens

TODO:

  • Delete token
  • How to handle logout

Closes DEV-2308

@linear
Copy link

linear bot commented Mar 28, 2022

@samuelmasse samuelmasse marked this pull request as ready for review March 29, 2022 21:31
this.props.mergeConfig!(data.payload)

const oldUserId = this.socket.socket.userId
await this.socket.reload(data.payload)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We only want to reconnect when some of the config changed, not for all of them

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made it so the reload function of the socket checks if reconnection is needed

packages/server/src/user-tokens/api.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@laurentlp laurentlp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small comment otherwise LGTM

packages/client/test/e2e/client.test.ts Show resolved Hide resolved
@samuelmasse samuelmasse merged commit 52028f8 into master Mar 30, 2022
@samuelmasse samuelmasse deleted the sm-user-tokens-api branch March 30, 2022 16:12
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

Successfully merging this pull request may close these issues.

None yet

2 participants