hide protected keys from config

This commit is contained in:
wvengen 2014-06-21 18:01:02 +02:00
parent 90f60595e6
commit 429e111db4
2 changed files with 4 additions and 1 deletions

View file

@ -130,7 +130,7 @@ class FoodsoftConfig
# @return [Boolean] Whether this key may be set in the database
def allowed_key?(key)
# fast check for keys without nesting
return !self.config[:protected].keys.include?(key)
return !self.config[:protected].keys.include?(key.to_s)
# @todo allow to check nested keys as well
end