Skip to content

FIX: Add primary email when user has no email

Administrator requested to merge bee/emailbug into main

Created by: abeatrix

This PR is to address the issue reported in https://github.com/sourcegraph/sourcegraph/issues/24976

Adding an email to accounts with no existing emails will break the email setting page for the user. This bug is blocking our customers from using Code Monitor. The root cause was the backend not being able to locate the primary email for the account in the database after an email has been added. To resolve this, we could check if the user has any existing email in their account when trying to add a new email and set the newly added email as the primary email if the account has no existing email.

image

image

Merge request reports

Loading