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

(PC-31571)[API] feat: discord auth full flow from our form #13934

Merged
merged 1 commit into from
Sep 5, 2024

Conversation

lixxday
Copy link
Contributor

@lixxday lixxday commented Sep 2, 2024

But de la pull request

Ticket Jira (ou description si BSR) : https://passculture.atlassian.net/browse/PC-31571

Vérifications

  • J'ai écrit les tests nécessaires
  • J'ai ajouté des screenshots pour d'éventuels changements graphiques

Screen pas ouf d'une réussite au 3e essai
https://github.com/user-attachments/assets/5cf37f56-4ea2-4b42-9e75-2ee093a0d2be

if discord_user is None:
# We still add the user to the database even if he doesn't have access to the discord server
discord_user = user_models.DiscordUser(userId=user.id, discordId=discord_id, hasAccess=False)
db.session.add(discord_user)
Copy link
Contributor

Choose a reason for hiding this comment

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

il faudrait prendre l'habitude de db.session.flush() juste après les add pour éviter que des erreurs potentielles soient remontées au niveau du décorateur atomic

@lixxday lixxday merged commit 23d2b52 into master Sep 5, 2024
23 checks passed
@lixxday lixxday deleted the PC-31571-update-discord-flow branch September 5, 2024 07:20
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.

4 participants