提交 6e9554cf 编写于 作者: J Justin Collins

Merge branch 'skip_unknown_configs_rails_3'

......@@ -72,6 +72,14 @@ class Brakeman::Rails3ConfigProcessor < Brakeman::BaseProcessor
level = @tracker.config[:rails]
options[0..-2].each do |o|
level[o] ||= {}
option = level[o]
if not option.is_a? Hash
Brakeman.debug "[Notice] Skipping config setting: #{options.map(&:to_s).join(".")}"
return exp
end
level = level[o]
end
......
......@@ -58,5 +58,9 @@ module Rails32
# Version of your assets, change this if you want to expire all your assets
config.assets.version = '1.0'
config.mess_things_up_in_prod = ActiveSupport::OrderedOptions.new
config.actually_a_hash = {}
end
end
......@@ -65,4 +65,9 @@ Rails32::Application.configure do
# with SQLite, MySQL, and PostgreSQL)
# config.active_record.auto_explain_threshold_in_seconds = 0.5
config.active_record.whitelist_attributes = true
# These configs actually resolve to values from application.rb
# but that's atypical, so going to skip for now or else errors
config.mess_things_up_in_prod.right_here = :nope_ignored
config.actually_a_hash[:thing] = 'cool setting'
end
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册