From ed8bf48c52cae4be01ae6133c22f5233cac69c97 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Fri, 22 Jul 2011 18:52:33 +0530 Subject: [PATCH] bugfix on profile save for guest and admin --- cgi-bin/core/doctype/profile/profile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cgi-bin/core/doctype/profile/profile.py b/cgi-bin/core/doctype/profile/profile.py index d4684a7bf3..dc145b809b 100644 --- a/cgi-bin/core/doctype/profile/profile.py +++ b/cgi-bin/core/doctype/profile/profile.py @@ -20,13 +20,13 @@ class DocType: import re from webnotes.utils import validate_email_add - self.doc.email = self.doc.email.strip() if self.doc.name not in ('Guest','Administrator'): + self.doc.email = self.doc.email.strip() if not validate_email_add(self.doc.email): msgprint("%s is not a valid email id" % self.doc.email) raise Exception - self.doc.name = self.doc.email + self.doc.name = self.doc.email def on_update(self): # owner is always name