about summary refs log tree commit diff
path: root/app/models/status.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2022-03-01 22:20:29 +0100
committerGitHub <noreply@github.com>2022-03-01 22:20:29 +0100
commit25d3dc4373531071f444d8e44e44cd21970cb373 (patch)
treec58f2e336ebdc3e15de07395bde6dd3ed80a4e24 /app/models/status.rb
parent14919fe11e9a1dd5cbf12969a2957d0d05bb0534 (diff)
Add ability to mark statuses as sensitive from reports in admin UI (#17668)
* Add ability to mark statuses as sensitive from reports in admin UI

* Allow mark as sensitive action on statuses with preview cards
Diffstat (limited to 'app/models/status.rb')
-rw-r--r--app/models/status.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/status.rb b/app/models/status.rb
index adb92ef91..60dde5045 100644
--- a/app/models/status.rb
+++ b/app/models/status.rb
@@ -231,6 +231,10 @@ class Status < ApplicationRecord
     media_attachments.any?
   end
 
+  def with_preview_card?
+    preview_cards.any?
+  end
+
   def non_sensitive_with_media?
     !sensitive? && with_media?
   end