Merge pull request #1254 from consul/password-changed-at
sets default value for password_changed_at
This commit is contained in:
5
db/migrate/20161102133838_default_password_changed_at.rb
Normal file
5
db/migrate/20161102133838_default_password_changed_at.rb
Normal file
@@ -0,0 +1,5 @@
|
||||
class DefaultPasswordChangedAt < ActiveRecord::Migration
|
||||
def change
|
||||
change_column :users, :password_changed_at, :datetime, null: false, default: Time.now
|
||||
end
|
||||
end
|
||||
12
db/schema.rb
12
db/schema.rb
@@ -11,7 +11,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 20160901104320) do
|
||||
ActiveRecord::Schema.define(version: 20161102133838) do
|
||||
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "plpgsql"
|
||||
@@ -413,17 +413,17 @@ ActiveRecord::Schema.define(version: 20160901104320) do
|
||||
|
||||
create_table "users", force: :cascade do |t|
|
||||
t.string "email", default: ""
|
||||
t.string "encrypted_password", default: "", null: false
|
||||
t.string "encrypted_password", default: "", null: false
|
||||
t.string "reset_password_token"
|
||||
t.datetime "reset_password_sent_at"
|
||||
t.datetime "remember_created_at"
|
||||
t.integer "sign_in_count", default: 0, null: false
|
||||
t.integer "sign_in_count", default: 0, null: false
|
||||
t.datetime "current_sign_in_at"
|
||||
t.datetime "last_sign_in_at"
|
||||
t.string "current_sign_in_ip"
|
||||
t.string "last_sign_in_ip"
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.string "confirmation_token"
|
||||
t.datetime "confirmed_at"
|
||||
t.datetime "confirmation_sent_at"
|
||||
@@ -464,7 +464,7 @@ ActiveRecord::Schema.define(version: 20160901104320) do
|
||||
t.boolean "email_digest", default: true
|
||||
t.boolean "email_on_direct_message", default: true
|
||||
t.boolean "official_position_badge", default: false
|
||||
t.datetime "password_changed_at"
|
||||
t.datetime "password_changed_at", default: '2016-11-02 13:51:14', null: false
|
||||
end
|
||||
|
||||
add_index "users", ["confirmation_token"], name: "index_users_on_confirmation_token", unique: true, using: :btree
|
||||
|
||||
Reference in New Issue
Block a user