X-Git-Url: https://projects.mako.cc/source/selectricity/blobdiff_plain/c65b1e11059c5cf510b54c785d4a246215058f70..1620856a8a47219f3a2cbb5288137b11467886fc:/app/models/token.rb diff --git a/app/models/token.rb b/app/models/token.rb index 2bab513..4ed9598 100644 --- a/app/models/token.rb +++ b/app/models/token.rb @@ -5,7 +5,7 @@ class Token < ActiveRecord::Base super token_generator = UniqueTokenGenerator.new( 16 ) - until not token.empty? and Token.find_all( [ "token = ?", token ]).empty? + until not token.empty? and Token.find(:all, :conditions => [ "token = ?", token ]).empty? self.token = token_generator.token end