Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added SwissMatch::ZipCodes#empty?

  • Loading branch information...
commit fd6c3dbff4582f587e29a35102aa70a2754daa16 1 parent cf52152
@awd-switzerland awd-switzerland authored
Showing with 6 additions and 0 deletions.
  1. +6 −0 lib/swissmatch/zipcodes.rb
View
6 lib/swissmatch/zipcodes.rb
@@ -246,6 +246,12 @@ def to_a
@zip_codes.dup
end
+ # @return [true, false] Whether this zip code collection contains any zip codes.
+ def empty?
+ @zip_codes.size.zero?
+ end
+ alias blank? empty?
+
# @private
# @see Object#inspect
def inspect
Please sign in to comment.
Something went wrong with that request. Please try again.