about summary refs log tree commit diff
path: root/db
diff options
context:
space:
mode:
authorDavid Yip <yipdw@member.fsf.org>2018-06-12 19:28:08 -0500
committerGitHub <noreply@github.com>2018-06-12 19:28:08 -0500
commitf1bfcb50f0baeecf445bfdcf2852b3826d0d3cc0 (patch)
tree83c564879534ea35f468ce319342e011773f24aa /db
parentf6bb50b6ece555af138df164680189b1ec57da4b (diff)
parent5cff053944b4327477ca45882c9dd3b1a7a559e8 (diff)
Merge pull request #531 from glitch-soc/454-allow-keyword-mutes-to-skip-mentions
Allow keyword mutes to skip mentions (#454)
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20180604000556_add_apply_to_mentions_flag_to_keyword_mutes.rb17
-rw-r--r--db/schema.rb5
2 files changed, 20 insertions, 2 deletions
diff --git a/db/migrate/20180604000556_add_apply_to_mentions_flag_to_keyword_mutes.rb b/db/migrate/20180604000556_add_apply_to_mentions_flag_to_keyword_mutes.rb
new file mode 100644
index 000000000..cd97d0f20
--- /dev/null
+++ b/db/migrate/20180604000556_add_apply_to_mentions_flag_to_keyword_mutes.rb
@@ -0,0 +1,17 @@
+require 'mastodon/migration_helpers'
+
+class AddApplyToMentionsFlagToKeywordMutes < ActiveRecord::Migration[5.2]
+  include Mastodon::MigrationHelpers
+
+  disable_ddl_transaction!
+
+  def up
+    safety_assured do
+      add_column_with_default :glitch_keyword_mutes, :apply_to_mentions, :boolean, allow_null: false, default: true
+    end
+  end
+
+  def down
+    remove_column :glitch_keyword_mutes, :apply_to_mentions
+  end
+end
diff --git a/db/schema.rb b/db/schema.rb
index 709859ab8..b1e586944 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -10,8 +10,9 @@
 #
 # It's strongly recommended that you check this file into your version control system.
 
-ActiveRecord::Schema.define(version: 2018_06_09_104432) do
 
+ActiveRecord::Schema.define(version: 2018_06_09_104432) do
+  
   # These are extensions that must be enabled in order to support this database
   enable_extension "plpgsql"
 
@@ -206,6 +207,7 @@ ActiveRecord::Schema.define(version: 2018_06_09_104432) do
     t.boolean "whole_word", default: true, null: false
     t.datetime "created_at", null: false
     t.datetime "updated_at", null: false
+    t.boolean "apply_to_mentions", default: true, null: false
     t.index ["account_id"], name: "index_glitch_keyword_mutes_on_account_id"
   end
 
@@ -466,7 +468,6 @@ ActiveRecord::Schema.define(version: 2018_06_09_104432) do
     t.bigint "application_id"
     t.bigint "in_reply_to_account_id"
     t.boolean "local_only"
-    t.text "full_status_text", default: "", null: false
     t.index ["account_id", "id", "visibility", "updated_at"], name: "index_statuses_20180106", order: { id: :desc }
     t.index ["conversation_id"], name: "index_statuses_on_conversation_id"
     t.index ["in_reply_to_id"], name: "index_statuses_on_in_reply_to_id"