summaryrefslogtreecommitdiffstats
path: root/lib/redmine/asset_path.rb
diff options
context:
space:
mode:
authorGo MAEDA <maeda@farend.jp>2024-01-26 08:29:59 +0000
committerGo MAEDA <maeda@farend.jp>2024-01-26 08:29:59 +0000
commita547662ad04c144b364203027e26ef69bfebbea6 (patch)
tree5c3689517afd650d2822e0537970636e2f77dee4 /lib/redmine/asset_path.rb
parent14e35236ad116c5e8215c3c2e4533fd90f8e51e1 (diff)
downloadredmine-a547662ad04c144b364203027e26ef69bfebbea6.tar.gz
redmine-a547662ad04c144b364203027e26ef69bfebbea6.zip
Fix RuboCop offense Style/MapToHash (#39111).
git-svn-id: https://svn.redmine.org/redmine/trunk@22644 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/redmine/asset_path.rb')
-rw-r--r--lib/redmine/asset_path.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/redmine/asset_path.rb b/lib/redmine/asset_path.rb
index b05a5f6f8..b115fe187 100644
--- a/lib/redmine/asset_path.rb
+++ b/lib/redmine/asset_path.rb
@@ -171,7 +171,7 @@ module Redmine
def cache_sweeper
@cache_sweeper ||= begin
exts_to_watch = Mime::EXTENSION_LOOKUP.map(&:first)
- files_to_watch = Array(all_paths).collect { |dir| [dir.to_s, exts_to_watch] }.to_h
+ files_to_watch = Array(all_paths).to_h { |dir| [dir.to_s, exts_to_watch] }
Rails.application.config.file_watcher.new([], files_to_watch) do
clear_cache
end