From cec005068f25c6487331a8437e69f29d5bef3d60 Mon Sep 17 00:00:00 2001 From: Nick Schonning Date: Tue, 7 Feb 2023 18:58:18 -0500 Subject: Apply Rubocop Performance/RedundantBlockCall (#23440) --- app/models/trends/history.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/models/trends') diff --git a/app/models/trends/history.rb b/app/models/trends/history.rb index 74723e35c..03d62103f 100644 --- a/app/models/trends/history.rb +++ b/app/models/trends/history.rb @@ -88,7 +88,7 @@ class Trends::History def each(&block) if block_given? - (0...7).map { |i| block.call(get(i.days.ago)) } + (0...7).map { |i| yield(get(i.days.ago)) } else to_enum(:each) end -- cgit