mirror of
https://github.com/go-gitea/gitea
synced 2024-11-21 23:21:08 +01:00
Merge branch 'master' of github.com:gogits/gogs
This commit is contained in:
commit
b192b70aec
1 changed files with 1 additions and 4 deletions
|
@ -145,10 +145,7 @@ func CreateRepository(user *User, repoName, desc, repoLang, license string, priv
|
|||
return nil, err
|
||||
}
|
||||
|
||||
rawSql := "UPDATE user SET num_repos = num_repos + 1 WHERE id = ?"
|
||||
if base.Cfg.MustValue("database", "DB_TYPE") == "postgres" {
|
||||
rawSql = "UPDATE \"user\" SET num_repos = num_repos + 1 WHERE id = ?"
|
||||
}
|
||||
rawSql := "UPDATE `user` SET num_repos = num_repos + 1 WHERE id = ?"
|
||||
if _, err = session.Exec(rawSql, user.Id); err != nil {
|
||||
session.Rollback()
|
||||
if err2 := os.RemoveAll(repoPath); err2 != nil {
|
||||
|
|
Loading…
Reference in a new issue