diff options
author | Ruben Davila <rdavila84@gmail.com> | 2017-04-20 07:19:24 +0300 |
---|---|---|
committer | Ruben Davila <rdavila84@gmail.com> | 2017-04-20 07:19:24 +0300 |
commit | 1de135bc0408a871e3bfa8b0ba5aa81a7936bd01 (patch) | |
tree | 433d3abbe19a48c5d67371ee8bc847fbcd3bf87e /db/migrate/20170413035209_add_preferred_language_to_users.rb | |
parent | 302e855f52b5d914e64bf6fbcc7e6544904c4e77 (diff) |
Fix Rubocop complains plus some small refactor
Diffstat (limited to 'db/migrate/20170413035209_add_preferred_language_to_users.rb')
-rw-r--r-- | db/migrate/20170413035209_add_preferred_language_to_users.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/db/migrate/20170413035209_add_preferred_language_to_users.rb b/db/migrate/20170413035209_add_preferred_language_to_users.rb index 5dc128dbaea..6fe91656eeb 100644 --- a/db/migrate/20170413035209_add_preferred_language_to_users.rb +++ b/db/migrate/20170413035209_add_preferred_language_to_users.rb @@ -8,7 +8,11 @@ class AddPreferredLanguageToUsers < ActiveRecord::Migration disable_ddl_transaction! - def change + def up add_column_with_default :users, :preferred_language, :string, default: 'en' end + + def down + remove_column :users, :preferred_language + end end |