Permalink
Browse files

Fixed the brokeness from 952ec79

  • Loading branch information...
1 parent 4b4aa8f commit 29641ff05ad1beb659582a3c4347c1395f940285 @dhh dhh committed Jun 3, 2008
Showing with 1 addition and 1 deletion.
  1. +1 −1 activesupport/lib/active_support/core_ext/hash/slice.rb
@@ -16,7 +16,7 @@ module Slice
def slice(*keys)
allowed = Set.new(respond_to?(:convert_key) ? keys.map { |key| convert_key(key) } : keys)
hash = {}
- allowed.each { |k| hash[k] = self[k] }
+ allowed.each { |k| hash[k] = self[k] if has_key?(k) }
hash
end

0 comments on commit 29641ff

Please sign in to comment.