Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Remove warnings on Ruby 2.1

  • Loading branch information...
commit 5402b72faafecfa1eda8afce0e0f194fcf385fe3 1 parent 7252b43
Rafael Mendonça França rafaelfranca authored
6 activesupport/lib/active_support/hash_with_indifferent_access.rb
View
@@ -228,7 +228,11 @@ def deep_symbolize_keys; to_hash.deep_symbolize_keys! end
def to_options!; self end
def select(*args, &block)
- dup.tap {|hash| hash.select!(*args, &block)}
+ dup.tap { |hash| hash.select!(*args, &block)}
+ end
+
+ def reject(*args, &block)
+ dup.tap { |hash| hash.reject!(*args, &block)}
end
# Convert to a regular hash with string keys.
4 activesupport/lib/active_support/ordered_hash.rb
View
@@ -28,6 +28,10 @@ def encode_with(coder)
coder.represent_seq '!omap', map { |k,v| { k => v } }
end
+ def reject(*args, &block)
+ dup.tap { |hash| hash.reject!(*args, &block)}
+ end
+
def nested_under_indifferent_access
self
end
Please sign in to comment.
Something went wrong with that request. Please try again.