Return everyone on an empty search

This commit is contained in:
Raphael 2010-10-12 18:18:03 -07:00
parent 6f2f9afe56
commit fe0120cc0d

View file

@ -34,6 +34,7 @@ class Person
/^(https?):\/\/[a-z0-9]+([\-\.]{1}[a-z0-9]+)*(\.[a-z]{2,5})?(:[0-9]{1,5})?(\/.*)?$/ix
def self.search(query)
return Person.all if query.to_s.empty?
qTokens = query.to_s.strip.split(" ")
fullQueryText = Regexp.escape( query.to_s.strip )
p = []