Skip to content

Auth user upload: Ignore pre-existing records #3

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

Merged

Conversation

sauntimo
Copy link
Contributor

@sauntimo sauntimo commented Feb 24, 2022

Background

  • I found when uploading users that the script failed because I had already created a user who had the same email address as one of the users in the users.json file.

Changes

  • adds ON CONFLICT DO NOTHING to the sql statement as I believe it's a reasonably likely scenario that people experimenting with migrating or working in dev envs might run into this situation and the users they have already created are likely to be valid.
  • also updates the related .js file (sorry, my tsc seems to treat string concatenation slightly differently...)

@burggraf burggraf merged commit 332ca8c into supabase-community:main Feb 24, 2022
burggraf added a commit that referenced this pull request Feb 24, 2022
Auth user upload: Ignore pre-existing records
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.

2 participants