about summary refs log tree commit diff
path: root/app/models/setting.rb
diff options
context:
space:
mode:
authorNick Schonning <nschonni@gmail.com>2023-02-08 01:06:50 -0500
committerGitHub <noreply@github.com>2023-02-08 07:06:50 +0100
commit8c1b65c7ddb9d49cb33c15c9a92dbfefebe868c6 (patch)
tree2fe80dcbbf7478b07071c2fb260d906a604103c8 /app/models/setting.rb
parent1487fcde93fece43ea786faade93d3dfaa393e67 (diff)
Apply Rubocop Style/RedundantAssignment (#23452)
Diffstat (limited to 'app/models/setting.rb')
-rw-r--r--app/models/setting.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/app/models/setting.rb b/app/models/setting.rb
index 4bcaa060f..c6558d692 100644
--- a/app/models/setting.rb
+++ b/app/models/setting.rb
@@ -23,7 +23,7 @@ class Setting < RailsSettings::Base
     def [](key)
       return super(key) unless rails_initialized?
 
-      val = Rails.cache.fetch(cache_key(key, nil)) do
+      Rails.cache.fetch(cache_key(key, nil)) do
         db_val = object(key)
 
         if db_val
@@ -35,7 +35,6 @@ class Setting < RailsSettings::Base
           default_settings[key]
         end
       end
-      val
     end
 
     def all_as_records