Skip to content

Add verified to User#13461

Open
YodaLightsabr wants to merge 2 commits intomainfrom
add-verified-boolean-to-user
Open

Add verified to User#13461
YodaLightsabr wants to merge 2 commits intomainfrom
add-verified-boolean-to-user

Conversation

@YodaLightsabr
Copy link
Copy Markdown
Contributor

@YodaLightsabr YodaLightsabr commented Apr 11, 2026

Summary of the problem

We're looking to allow users to create new accounts and set certain attributes on User prior to verifying their email address. As a result, we want to store in the DB whether or not a user is verified.

Describe your changes

Before we can build out protections against unverified users, we want to make sure that all existing users are backfilled as verified and that new users signing in get marked as verified.

@YodaLightsabr YodaLightsabr requested a review from a team April 11, 2026 14:53
@YodaLightsabr YodaLightsabr requested a review from garyhtou as a code owner April 11, 2026 14:53
@@ -0,0 +1,5 @@
class AddVerifiedToUser < ActiveRecord::Migration[8.0]
def change
add_column :users, :verified, :boolean, default: false, null: false
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
add_column :users, :verified, :boolean, default: false, null: false
add_column :users, :verified, :boolean, default: true, null: false
change_column_default :users, :verified, from: true, to: false

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