lib/secure_headers/railtie.rb in secure_headers-3.9.0 vs lib/secure_headers/railtie.rb in secure_headers-4.0.0.alpha01

- old
+ new

@@ -1,21 +1,22 @@ +# frozen_string_literal: true # rails 3.1+ if defined?(Rails::Railtie) module SecureHeaders class Railtie < Rails::Railtie isolate_namespace SecureHeaders if defined? isolate_namespace # rails 3.0 - conflicting_headers = ['X-Frame-Options', 'X-XSS-Protection', - 'X-Permitted-Cross-Domain-Policies', 'X-Download-Options', - 'X-Content-Type-Options', 'Strict-Transport-Security', - 'Content-Security-Policy', 'Content-Security-Policy-Report-Only', - 'Public-Key-Pins', 'Public-Key-Pins-Report-Only', 'Referrer-Policy'] + conflicting_headers = ["X-Frame-Options", "X-XSS-Protection", + "X-Permitted-Cross-Domain-Policies", "X-Download-Options", + "X-Content-Type-Options", "Strict-Transport-Security", + "Content-Security-Policy", "Content-Security-Policy-Report-Only", + "Public-Key-Pins", "Public-Key-Pins-Report-Only", "Referrer-Policy"] initializer "secure_headers.middleware" do Rails.application.config.middleware.insert_before 0, SecureHeaders::Middleware end rake_tasks do - load File.expand_path(File.join('..', '..', 'lib', 'tasks', 'tasks.rake'), File.dirname(__FILE__)) + load File.expand_path(File.join("..", "..", "lib", "tasks", "tasks.rake"), File.dirname(__FILE__)) end initializer "secure_headers.action_controller" do ActiveSupport.on_load(:action_controller) do include SecureHeaders