File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -334,13 +334,11 @@ func RepoAssignment(args ...bool) macaron.Handler {
334334 if ctx .Repo .IsWriter () || (ctx .IsSigned && ctx .User .HasForkedRepo (ctx .Repo .Repository .ID )) {
335335 // Pull request is allowed if this is a fork repository
336336 // and base repository accepts pull requests.
337- if repo .BaseRepo != nil {
338- if repo .BaseRepo .AllowsPulls () {
339- ctx .Data ["BaseRepo" ] = repo .BaseRepo
340- ctx .Repo .PullRequest .BaseRepo = repo .BaseRepo
341- ctx .Repo .PullRequest .Allowed = true
342- ctx .Repo .PullRequest .HeadInfo = ctx .Repo .Owner .Name + ":" + ctx .Repo .BranchName
343- }
337+ if repo .BaseRepo != nil && repo .BaseRepo .AllowsPulls () {
338+ ctx .Data ["BaseRepo" ] = repo .BaseRepo
339+ ctx .Repo .PullRequest .BaseRepo = repo .BaseRepo
340+ ctx .Repo .PullRequest .Allowed = true
341+ ctx .Repo .PullRequest .HeadInfo = ctx .Repo .Owner .Name + ":" + ctx .Repo .BranchName
344342 } else {
345343 // Or, this is repository accepts pull requests between branches.
346344 if repo .AllowsPulls () {
You can’t perform that action at this time.
0 commit comments