From 30c5736413215c222ce43386140ee0dc780bc9a7 Mon Sep 17 00:00:00 2001 From: Ken Johnson Date: Sun, 28 Apr 2013 15:23:43 -0400 Subject: [PATCH] caused too much unexpected weirdness although would have been fun as a bug, had to remove --- app/models/user.rb | 4 ---- 1 file changed, 4 deletions(-) diff --git a/app/models/user.rb b/app/models/user.rb index 1055b26..ca3b328 100755 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -4,10 +4,6 @@ class User < ActiveRecord::Base validates :password, :presence => true, :confirmation => true, :length => {:within => 6..40} - # I think this makes sense, have both, right? If we are updating our password and creating one? - :on => :create, - :on => :update - # Solution? Remove both :on => statements, it will naturally take effect for any changes. validates_presence_of :email validates_uniqueness_of :email validates_format_of :email, :with => /.+@.+\..+/i