Fix Style/GuardClause in User#regenerate_feed! (#35523)
This commit is contained in:
@@ -540,10 +540,10 @@ class User < ApplicationRecord
|
|||||||
|
|
||||||
def regenerate_feed!
|
def regenerate_feed!
|
||||||
home_feed = HomeFeed.new(account)
|
home_feed = HomeFeed.new(account)
|
||||||
unless home_feed.regenerating?
|
return if home_feed.regenerating?
|
||||||
home_feed.regeneration_in_progress!
|
|
||||||
RegenerationWorker.perform_async(account_id)
|
home_feed.regeneration_in_progress!
|
||||||
end
|
RegenerationWorker.perform_async(account_id)
|
||||||
end
|
end
|
||||||
|
|
||||||
def needs_feed_update?
|
def needs_feed_update?
|
||||||
|
|||||||
Reference in New Issue
Block a user