Permalink
Browse files

Documented Array#blank?

  • Loading branch information...
1 parent c497999 commit ceeed213a96d2f893838f9304b3953a1fc727cfc @smartinez87 smartinez87 committed Apr 17, 2011
Showing with 6 additions and 1 deletion.
  1. +6 −1 activesupport/lib/active_support/core_ext/object/blank.rb
@@ -67,7 +67,12 @@ def blank?
end
end
-class Array #:nodoc:
+class Array
+ # An array is blank if it's empty
+ # For example:
+ #
+ # [].blank? => true
+ # [1,2,3].blank? => false
alias_method :blank?, :empty?
end

0 comments on commit ceeed21

Please sign in to comment.