This repository has been archived on 2024-07-31. You can view files and clone it, but cannot push or open issues or pull requests.
2023-07-12 03:47:08 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2018-07-08 20:22:09 -04:00
|
|
|
require Rails.root.join('lib', 'mastodon', 'migration_helpers')
|
|
|
|
|
|
|
|
class AddWholeWordToCustomFilter < ActiveRecord::Migration[5.2]
|
|
|
|
include Mastodon::MigrationHelpers
|
|
|
|
|
|
|
|
disable_ddl_transaction!
|
|
|
|
|
|
|
|
def change
|
|
|
|
safety_assured do
|
|
|
|
add_column_with_default :custom_filters, :whole_word, :boolean, default: true, allow_null: false
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
def down
|
|
|
|
remove_column :custom_filters, :whole_word
|
|
|
|
end
|
|
|
|
end
|