diff options
author | Unknown <joe2010xtmf@163.com> | 2014-03-27 21:15:53 -0400 |
---|---|---|
committer | Unknown <joe2010xtmf@163.com> | 2014-03-27 21:15:53 -0400 |
commit | 5344a0300383c4921e4a5810dff58c7686412f0c (patch) | |
tree | b1010551e0c1060f25eb69bdc7f5d66f5f2c844b /modules | |
parent | 8b700e825b7c39285cbc3e87a48b9bcb77864beb (diff) | |
download | gitea-5344a0300383c4921e4a5810dff58c7686412f0c.tar.gz gitea-5344a0300383c4921e4a5810dff58c7686412f0c.zip |
Bug fix
Diffstat (limited to 'modules')
-rw-r--r-- | modules/middleware/repo.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/middleware/repo.go b/modules/middleware/repo.go index bc90c05cc7..cb4a8632a2 100644 --- a/modules/middleware/repo.go +++ b/modules/middleware/repo.go @@ -56,7 +56,9 @@ func RepoAssignment(redirect bool) martini.Handler { // get repository repo, err := models.GetRepositoryByName(user.Id, params["reponame"]) if err != nil { - if redirect { + if err == models.ErrRepoNotExist { + ctx.Handle(404, "RepoAssignment", err) + } else if redirect { ctx.Redirect("/") return } |