Fix Rubocop offenses

This commit is contained in:
Sebastian Serth
2022-04-24 18:18:16 +02:00
parent 9994ebdb72
commit 038864e4b4
5 changed files with 6 additions and 6 deletions

View File

@ -76,7 +76,7 @@ Rails.application.configure do
# Raises helpful error messages.
config.assets.raise_runtime_errors = true
BetterErrors::Middleware.allow_ip! ENV['TRUSTED_IP'] if ENV['TRUSTED_IP']
BetterErrors::Middleware.allow_ip! ENV.fetch('TRUSTED_IP', nil) if ENV['TRUSTED_IP']
# Use an evented file watcher to asynchronously detect changes in source code,
# routes, locales, etc. This feature depends on the listen gem.

View File

@ -6,7 +6,7 @@ class SentryJavascript
end
def self.dsn
ENV['SENTRY_JAVASCRIPT_DSN']
ENV.fetch('SENTRY_JAVASCRIPT_DSN', nil)
end
def self.release

View File

@ -22,7 +22,7 @@
# Learn more: http://github.com/javan/whenever
set :output, "#{Whenever.path}/log/whenever/whenever_$(date +%Y%m%d%H%M%S).log"
set :environment, ENV['RAILS_ENV'] if ENV['RAILS_ENV']
set :environment, ENV.fetch('RAILS_ENV', nil) if ENV['RAILS_ENV']
every 1.day, at: '3:00 am' do
rake 'detect_exercise_anomalies:with_at_least[10,50]'