lib/cockpit/core/settings.rb in cockpit-0.2.1 vs lib/cockpit/core/settings.rb in cockpit-0.2.2

- old
+ new

@@ -109,11 +109,11 @@ def keys spec.keys end def [](key) - self.store[key.to_s] || default(key.to_s) + store.has_key?(key.to_s) ? self.store[key.to_s] : default(key.to_s) end def []=(key, value) with_callbacks(key, value) do |value| self.store[key.to_s] = value @@ -184,10 +184,10 @@ protected def method_missing(method, *args, &block) if method.to_s =~ /(\w+)\?$/ present?($1) - elsif has_key?(method) + elsif has_key?(method.to_s.gsub("=", "")) Cockpit::Scope.new(self, method, *args, &block) else super(method, *args, &block) end end