![](https://github.com/gogits/gogs/blob/master/public/img/gogs-large-resize.png?raw=true) | ![](https://github.com/gogits/gogs/blob/master/public/img/gogs-large-resize.png?raw=true) | ||||
##### Current tip version: 0.9.50 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions) | |||||
##### Current tip version: 0.9.51 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions) | |||||
| Web | UI | Preview | | | Web | UI | Preview | | ||||
|:-------------:|:-------:|:-------:| | |:-------------:|:-------:|:-------:| |
"github.com/gogits/gogs/modules/setting" | "github.com/gogits/gogs/modules/setting" | ||||
) | ) | ||||
const APP_VER = "0.9.50.0723" | |||||
const APP_VER = "0.9.51.0723" | |||||
func init() { | func init() { | ||||
runtime.GOMAXPROCS(runtime.NumCPU()) | runtime.GOMAXPROCS(runtime.NumCPU()) |
prInfo, err := headGitRepo.GetPullRequestInfo(models.RepoPath(repo.Owner.Name, repo.Name), | prInfo, err := headGitRepo.GetPullRequestInfo(models.RepoPath(repo.Owner.Name, repo.Name), | ||||
pull.BaseBranch, pull.HeadBranch) | pull.BaseBranch, pull.HeadBranch) | ||||
if err != nil { | if err != nil { | ||||
if strings.Contains(err.Error(), "fatal: Not a valid object name") { | |||||
ctx.Data["IsPullReuqestBroken"] = true | |||||
ctx.Data["BaseTarget"] = "deleted" | |||||
ctx.Data["NumCommits"] = 0 | |||||
ctx.Data["NumFiles"] = 0 | |||||
return nil | |||||
} | |||||
ctx.Handle(500, "GetPullRequestInfo", err) | ctx.Handle(500, "GetPullRequestInfo", err) | ||||
return nil | return nil | ||||
} | } |
0.9.50.0723 | |||||
0.9.51.0723 |