Permalink
Browse files

fixed NoMethodError

  • Loading branch information...
1 parent 26df825 commit eaec2c7870e89b9c028fb9c421538f45f80dbdd6 @lucasdicioccio lucasdicioccio committed Jan 24, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/em-imap/client.rb
View
2 lib/em-imap/client.rb
@@ -486,7 +486,7 @@ def normalize_search_criteria(args)
when "*", -1, Range
Net::IMAP::MessageSet.new(arg)
when Array
- if Array.all?{ |item| item.is_a?(Number) || item.is_a?(Range) }
+ if arg.inject(true){|bool,item| bool and (item.is_a?(Integer) or item.is_a?(Range))}
Net::IMAP::MessageSet.new(arg)
else
normalize_search_criteria(arg)

0 comments on commit eaec2c7

Please sign in to comment.