mirror of
https://github.com/mastodon/mastodon.git
synced 2024-12-25 10:17:47 +00:00
880a5eb25c
* Fix boolean columns sometimes having a null value * Fix wrong value being set instead of null
18 lines
620 B
Ruby
18 lines
620 B
Ruby
class FixNullBooleans < ActiveRecord::Migration[5.1]
|
|
def change
|
|
change_column_default :domain_blocks, :reject_media, false
|
|
change_column_null :domain_blocks, :reject_media, false, false
|
|
|
|
change_column_default :imports, :approved, false
|
|
change_column_null :imports, :approved, false, false
|
|
|
|
change_column_null :statuses, :sensitive, false, false
|
|
change_column_null :statuses, :reply, false, false
|
|
|
|
change_column_null :users, :admin, false, false
|
|
|
|
change_column_default :users, :otp_required_for_login, false
|
|
change_column_null :users, :otp_required_for_login, false, false
|
|
end
|
|
end
|