summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUnknwon <joe2010xtmf@163.com>2014-12-29 20:00:07 +0800
committerUnknwon <joe2010xtmf@163.com>2014-12-29 20:00:07 +0800
commit63c1f9a23fd9b3d756e6763005df9262ccb15101 (patch)
tree6d834560b79881c7e4512caa7d39fb5dd9861177
parent81a44e4cd0c4f4c2310b59624748ba0df9fcbe87 (diff)
downloadgitea-63c1f9a23fd9b3d756e6763005df9262ccb15101.tar.gz
gitea-63c1f9a23fd9b3d756e6763005df9262ccb15101.zip
fix 500: E-mail already used in user settings page
-rw-r--r--cmd/web.go6
-rw-r--r--gogs.go2
-rw-r--r--models/user.go2
-rw-r--r--templates/.VERSION2
4 files changed, 6 insertions, 6 deletions
diff --git a/cmd/web.go b/cmd/web.go
index 56df5fe721..ddb34829b7 100644
--- a/cmd/web.go
+++ b/cmd/web.go
@@ -74,11 +74,11 @@ func checkVersion() {
// Check dependency version.
checkers := []VerChecker{
- {"github.com/Unknwon/macaron", macaron.Version, "0.4.7"},
+ {"github.com/Unknwon/macaron", macaron.Version, "0.4.9"},
{"github.com/macaron-contrib/binding", binding.Version, "0.0.4"},
{"github.com/macaron-contrib/csrf", csrf.Version, "0.0.1"},
- {"github.com/macaron-contrib/i18n", i18n.Version, "0.0.4"},
- {"github.com/macaron-contrib/session", session.Version, "0.1.0"},
+ {"github.com/macaron-contrib/i18n", i18n.Version, "0.0.5"},
+ {"github.com/macaron-contrib/session", session.Version, "0.1.1"},
}
for _, c := range checkers {
ver := strings.Join(strings.Split(c.Version(), ".")[:3], ".")
diff --git a/gogs.go b/gogs.go
index 04141dad3d..c3038aad6d 100644
--- a/gogs.go
+++ b/gogs.go
@@ -17,7 +17,7 @@ import (
"github.com/gogits/gogs/modules/setting"
)
-const APP_VER = "0.5.10.1222 Beta"
+const APP_VER = "0.5.10.1229 Beta"
func init() {
runtime.GOMAXPROCS(runtime.NumCPU())
diff --git a/models/user.go b/models/user.go
index 651168eba2..f16fbca344 100644
--- a/models/user.go
+++ b/models/user.go
@@ -453,7 +453,7 @@ func ChangeUserName(u *User, newUserName string) (err error) {
// UpdateUser updates user's information.
func UpdateUser(u *User) error {
- has, err := x.Where("id!=?", u.Id).And("email=?", u.Email).Get(new(User))
+ has, err := x.Where("id!=?", u.Id).And("type=?", INDIVIDUAL).And("email=?", u.Email).Get(new(User))
if err != nil {
return err
} else if has {
diff --git a/templates/.VERSION b/templates/.VERSION
index 801600a4bd..ea5da339f7 100644
--- a/templates/.VERSION
+++ b/templates/.VERSION
@@ -1 +1 @@
-0.5.10.1222 Beta \ No newline at end of file
+0.5.10.1229 Beta \ No newline at end of file