app.kluk.fr/db/migrate/20260211102848_add_username_to_users.rb

8 lines
208 B
Ruby
Raw Permalink Normal View History

2026-02-18 15:56:33 +01:00
class AddUsernameToUsers < ActiveRecord::Migration[8.0]
def up
add_column :users, :username, :string
User.update_all(username: "temporary")
change_column_null :users, :username, false
end
end