aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2009-11-09 22:05:31 +0100
committerXavier Noria <fxn@hashref.com>2009-11-09 22:16:51 +0100
commitdb2c0d79e3f9ba4fa921b7a122e9e7849729de64 (patch)
treeb618926ddc352a130efdd7d8de0cd1736fdf6f31 /activesupport/lib
parent329e7f44417c00a8d6fee337c288a463e9d64346 (diff)
downloadrails-db2c0d79e3f9ba4fa921b7a122e9e7849729de64.tar.gz
rails-db2c0d79e3f9ba4fa921b7a122e9e7849729de64.tar.bz2
rails-db2c0d79e3f9ba4fa921b7a122e9e7849729de64.zip
Enumerable#none? is not needed for Ruby >= 1.8.7
Diffstat (limited to 'activesupport/lib')
-rw-r--r--activesupport/lib/active_support/core_ext/enumerable.rb9
1 files changed, 0 insertions, 9 deletions
diff --git a/activesupport/lib/active_support/core_ext/enumerable.rb b/activesupport/lib/active_support/core_ext/enumerable.rb
index 15a303cf04..b11c916f61 100644
--- a/activesupport/lib/active_support/core_ext/enumerable.rb
+++ b/activesupport/lib/active_support/core_ext/enumerable.rb
@@ -101,15 +101,6 @@ module Enumerable
size = block_given? ? select(&block).size : self.size
size > 1
end
-
- # Returns true if none of the elements match the given block.
- #
- # success = responses.none? {|r| r.status / 100 == 5 }
- #
- # This is a builtin method in Ruby 1.8.7 and later.
- def none?(&block)
- !any?(&block)
- end unless [].respond_to?(:none?)
end
class Range #:nodoc: