Merge remote-tracking branch 'parent/main' into upstream-20231110
This commit is contained in:
commit
bfc7b0101d
44 changed files with 992 additions and 744 deletions
|
@ -67,7 +67,7 @@ end
|
|||
# https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy-Report-Only
|
||||
# Rails.application.config.content_security_policy_report_only = true
|
||||
|
||||
Rails.application.config.content_security_policy_nonce_generator = ->(request) { SecureRandom.base64(16) }
|
||||
Rails.application.config.content_security_policy_nonce_generator = ->(_request) { SecureRandom.base64(16) }
|
||||
|
||||
Rails.application.config.content_security_policy_nonce_directives = %w(style-src)
|
||||
|
||||
|
@ -92,7 +92,7 @@ Rails.application.reloader.to_prepare do
|
|||
p.worker_src :none
|
||||
end
|
||||
|
||||
LetterOpenerWeb::LettersController.after_action do |p|
|
||||
LetterOpenerWeb::LettersController.after_action do
|
||||
request.content_security_policy_nonce_directives = %w(script-src)
|
||||
end
|
||||
end
|
||||
|
|
|
@ -171,7 +171,7 @@ Doorkeeper.configure do
|
|||
# Under some circumstances you might want to have applications auto-approved,
|
||||
# so that the user skips the authorization step.
|
||||
# For example if dealing with a trusted application.
|
||||
skip_authorization do |resource_owner, client|
|
||||
skip_authorization do |_resource_owner, client|
|
||||
client.application.superapp?
|
||||
end
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ Paperclip.interpolates :filename do |attachment, style|
|
|||
end
|
||||
end
|
||||
|
||||
Paperclip.interpolates :prefix_path do |attachment, style|
|
||||
Paperclip.interpolates :prefix_path do |attachment, _style|
|
||||
if attachment.storage_schema_version >= 1 && attachment.instance.respond_to?(:local?) && !attachment.instance.local?
|
||||
'cache' + File::SEPARATOR
|
||||
else
|
||||
|
@ -19,7 +19,7 @@ Paperclip.interpolates :prefix_path do |attachment, style|
|
|||
end
|
||||
end
|
||||
|
||||
Paperclip.interpolates :prefix_url do |attachment, style|
|
||||
Paperclip.interpolates :prefix_url do |attachment, _style|
|
||||
if attachment.storage_schema_version >= 1 && attachment.instance.respond_to?(:local?) && !attachment.instance.local?
|
||||
'cache/'
|
||||
else
|
||||
|
|
|
@ -43,6 +43,7 @@ end
|
|||
Sidekiq.logger.level = ::Logger.const_get(ENV.fetch('RAILS_LOG_LEVEL', 'info').upcase.to_s)
|
||||
|
||||
SidekiqUniqueJobs.configure do |config|
|
||||
config.enabled = !Rails.env.test?
|
||||
config.reaper = :ruby
|
||||
config.reaper_count = 1000
|
||||
config.reaper_interval = 600
|
||||
|
|
|
@ -188,7 +188,7 @@ SimpleForm.setup do |config|
|
|||
# config.item_wrapper_class = nil
|
||||
|
||||
# How the label text should be generated altogether with the required text.
|
||||
config.label_text = lambda { |label, required, explicit_label| "#{label} #{required}" }
|
||||
config.label_text = lambda { |label, required, _explicit_label| "#{label} #{required}" }
|
||||
|
||||
# You can define the class to use on all labels. Default is nil.
|
||||
# config.label_class = nil
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue