about summary refs log tree commit diff
path: root/app/services/fetch_link_card_service.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/services/fetch_link_card_service.rb')
-rw-r--r--app/services/fetch_link_card_service.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/services/fetch_link_card_service.rb b/app/services/fetch_link_card_service.rb
index f9b1b2f0c..86d0f9971 100644
--- a/app/services/fetch_link_card_service.rb
+++ b/app/services/fetch_link_card_service.rb
@@ -23,6 +23,8 @@ class FetchLinkCardService < BaseService
       if lock.acquired?
         @card = PreviewCard.find_by(url: @url)
         process_url if @card.nil? || @card.updated_at <= 2.weeks.ago
+      else
+        raise Mastodon::RaceConditionError
       end
     end