about summary refs log tree commit diff
path: root/app/services
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2016-12-05 22:59:30 +0100
committerEugen Rochko <eugen@zeonfederated.com>2016-12-05 22:59:30 +0100
commit39cc9fde8a2e34da0639d83688d4d6d6d6240382 (patch)
tree2f41f57b6e21dacbb6dd67b8db73a5fac4a08493 /app/services
parent64d109dc0e39574d4ed45f2443ee132dfb761033 (diff)
Add account suspension
Diffstat (limited to 'app/services')
-rw-r--r--app/services/process_feed_service.rb2
-rw-r--r--app/services/process_interaction_service.rb2
2 files changed, 4 insertions, 0 deletions
diff --git a/app/services/process_feed_service.rb b/app/services/process_feed_service.rb
index 3aa0ceff8..1a831fa73 100644
--- a/app/services/process_feed_service.rb
+++ b/app/services/process_feed_service.rb
@@ -93,6 +93,8 @@ class ProcessFeedService < BaseService
         account = @account
       end
 
+      return if account.suspended?
+
       status = Status.create!(
         uri: id(entry),
         url: url(entry),
diff --git a/app/services/process_interaction_service.rb b/app/services/process_interaction_service.rb
index 129b2a2be..4e5487681 100644
--- a/app/services/process_interaction_service.rb
+++ b/app/services/process_interaction_service.rb
@@ -23,6 +23,8 @@ class ProcessInteractionService < BaseService
       account = follow_remote_account_service.call("#{username}@#{domain}")
     end
 
+    return if account.suspended?
+
     if salmon.verify(envelope, account.keypair)
       update_remote_profile_service.call(xml.at_xpath('/xmlns:entry', xmlns: TagManager::XMLNS), account, true)