From efffdd3778fc960280c7677906ed43dae5a952b0 Mon Sep 17 00:00:00 2001 From: abcang Date: Thu, 7 Jan 2021 17:40:55 +0900 Subject: Fix rubocop config and warnings (#15503) * disable NewCops * update TargetRubyVersion * Fix Lint/MissingSuper for ActiveModelSerializers::Model * Fix Lint/MissingSuper for feed * Fix Lint/FloatComparison * Do not use instance variables --- app/models/home_feed.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'app/models/home_feed.rb') diff --git a/app/models/home_feed.rb b/app/models/home_feed.rb index 0fe9dae46..d6ebb5fa6 100644 --- a/app/models/home_feed.rb +++ b/app/models/home_feed.rb @@ -2,12 +2,11 @@ class HomeFeed < Feed def initialize(account) - @type = :home - @id = account.id @account = account + super(:home, account.id) end def regenerating? - redis.exists?("account:#{@id}:regeneration") + redis.exists?("account:#{@account.id}:regeneration") end end -- cgit