summaryrefslogtreecommitdiff
path: root/user.go
diff options
context:
space:
mode:
authorHorus32015-03-23 16:22:21 +0100
committerHorus32015-03-23 16:22:21 +0100
commitac1ee887205d068b7b1c1df690f157dda506e419 (patch)
tree94cbabac47acab058c98cdb5e77f2cfdf259640a /user.go
parent5ff2678063792a74868c231ec68e30ef4397dece (diff)
downloadfreemail-ac1ee887205d068b7b1c1df690f157dda506e419.tar.gz
Reorder and restyle alert messages. Fixed bug in AuthUser(). Remove some unnecessary CSS.
Diffstat (limited to 'user.go')
-rw-r--r--user.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/user.go b/user.go
index f491eea..9f5064e 100644
--- a/user.go
+++ b/user.go
@@ -9,6 +9,9 @@ func (vU VirtualUser) HashPassword() string {
}
func (vU VirtualUser) AuthUser() bool {
+ if !vU.EmailExists() {
+ return false
+ }
passwd := vU.Password
Db.Where("email = ?", vU.Email).Find(&vU)
if vU.Password == passwd {