lib/auth_helpers.rb in josevalim-auth_helpers-0.3.1 vs lib/auth_helpers.rb in josevalim-auth_helpers-0.3.2
- old
+ new
@@ -13,10 +13,10 @@
# Creates a new record, assigning the perishable token and an error message.
#
def self.new_with_perishable_token_error(klass, message=:invalid, options={})
record = klass.new(options)
record.perishable_token = options[:perishable_token]
- record.errors.add(:perishable_token, message, :default => :invalid)
+ record.errors.add(:perishable_token, message, :default => [:invalid])
record
end
end