Fix rubocop offense

This commit is contained in:
Alexander Meindl 2021-12-23 19:18:53 +01:00
parent 1e9bc03e47
commit 1b24dfa4d2

View File

@ -48,12 +48,9 @@ module Additionals
path = File.join plugins_dir, plugin_id
return if File.exist? path
File.open path, 'w' do |f|
f.write <<PLUGIN_HINT
This plugin was installed as gem wrote to Gemfile.local instead of putting Redmine's plugin directory.
See #{plugin_id} gem installed directory.
PLUGIN_HINT
end
File.write path,
"This plugin was installed as gem wrote to Gemfile.local instead of putting Redmine's plugin directory.\n" \
"See #{plugin_id} gem installed directory.\n"
rescue Errno::EACCES => e
Rails.logger.warn "Could not create plugin hint file: #{e.message}"
end