about summary refs log tree commit diff
path: root/app/models
diff options
context:
space:
mode:
authorFire Demon <firedemon@creature.cafe>2020-11-29 11:44:10 -0600
committerFire Demon <firedemon@creature.cafe>2020-11-29 11:44:10 -0600
commit870ebfe74e9b91249bad6cfaf2b3a5a650d19c2a (patch)
tree6c073f6a6611f74f32838a86ce5c489d4d583d41 /app/models
parent876b6dbf766372303ad5f646fdcba4dccde47ca4 (diff)
Simply Tavern curation checks
Diffstat (limited to 'app/models')
-rw-r--r--app/models/status.rb10
1 files changed, 8 insertions, 2 deletions
diff --git a/app/models/status.rb b/app/models/status.rb
index 67b975813..2e83e258b 100644
--- a/app/models/status.rb
+++ b/app/models/status.rb
@@ -309,11 +309,17 @@ class Status < ApplicationRecord
   end
 
   def curate!
-    update_column(:curated, true) if public_visibility? && !curated
+    return false unless !curated? && published? && public_visibility?
+
+    update_column(:curated, true)
+    true
   end
 
   def uncurate!
-    update_column(:curated, false) if curated
+    return false unless curated?
+
+    update_column(:curated, false)
+    true
   end
 
   def notify=(value)