Sha256: 6463627896004c7347dfb9f38dbd56ee33dfc2bf9c37ddda536b486ceafd3ade

Contents?: true

Size: 540 Bytes

Versions: 24

Compression:

Stored size: 540 Bytes

Contents

# frozen_string_literal: true

if defined?(ActionController::Parameters)
  always_permitted_parameters = %w{id}

  if ActionController::Parameters.respond_to?(:always_permitted_parameters)
    ActionController::Parameters.always_permitted_parameters += always_permitted_parameters
  else
    always_permitted_parameters.each do |always_permitted_parameter|
      ActionController::Parameters::NEVER_UNPERMITTED_PARAMS << always_permitted_parameter
    end
  end

  ActionController::Parameters.action_on_unpermitted_parameters = :raise
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
rspeckled-0.0.54 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.53 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.52 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.51 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.50 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.49 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.48 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.47 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.46 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.45 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.44 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.43 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.42 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.41 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.40 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.39 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.38 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.37 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.36 lib/rspeckled/plugins/rails/strong_parameters.rb
rspeckled-0.0.35 lib/rspeckled/plugins/rails/strong_parameters.rb