about summary refs log tree commit diff
path: root/app/models
diff options
context:
space:
mode:
authormultiple creatures <dev@multiple-creature.party>2019-04-22 16:46:41 -0500
committermultiple creatures <dev@multiple-creature.party>2019-05-21 03:16:22 -0500
commitaf7e3a88d4a6574564b75da1ddd56b45819fd0a7 (patch)
tree728436a5ec2df9f9ca7e41eb6d9c2fae3ab2cbbd /app/models
parent15b35d99ce296b06b9b82c9f9e85f0e1f2a571ac (diff)
Anxiety reduction: make block/mute reply filters more granular and add options to control what to filter.
Diffstat (limited to 'app/models')
-rw-r--r--app/models/user.rb30
1 files changed, 30 insertions, 0 deletions
diff --git a/app/models/user.rb b/app/models/user.rb
index bcfc49115..29db2e078 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -112,6 +112,12 @@ class User < ApplicationRecord
     :larger_buttons,
     :larger_drawer,
     :remove_filtered,
+    :hide_replies_muted,
+    :hide_replies_blocked,
+    :hide_replies_blocker,
+    :hide_mntions_muted,
+    :hide_mntions_blocked,
+    :hide_mntions_blocker,
     :gently_kobolds,
     :user_is_kobold,
 
@@ -232,6 +238,30 @@ class User < ApplicationRecord
     settings.remove_filtered || false
   end
 
+  def setting_hide_replies_muted
+    settings.hide_replies_muted || true
+  end
+
+  def setting_hide_replies_blocked
+    settings.hide_replies_blocked || true
+  end
+
+  def setting_hide_replies_blocker
+    settings.hide_replies_blocker || true
+  end
+
+  def setting_hide_mntions_muted
+    settings.hide_mntions_muted || true
+  end
+
+  def setting_hide_mntions_blocked
+    settings.hide_mntions_blocked || true
+  end
+
+  def setting_hide_mntions_blocker
+    settings.hide_mntions_blocker || true
+  end
+
   def setting_gently_kobolds
     settings.gently_kobolds || false
   end