Repository navigation
How To: Upgrade to Devise 2.0 migration schema style
josevalim edited this page Dec 5, 2011
·
8 revisions
Since Devise 2.0, it no longer includes helpers for your migrations. Instead, it simply lists the database fields explicitly. This page shows the before and after of the migrations so you can easily compare and update your code.
create_table(TABLE_NAME) do |t| t.database_authenticatable :null => false t.recoverable t.rememberable t.trackable # t.encryptable # t.confirmable # t.lockable :lock_strategy => :<%= Devise.lock_strategy %>, :unlock_stra # t.token_authenticatable end