handle find pr number 0
This commit is contained in:
parent
b52c131d4c
commit
06d22d96c0
1 changed files with 1 additions and 1 deletions
|
|
@ -245,7 +245,7 @@ func (f *finder) Find(opts FindOptions) (*api.PullRequest, ghrepo.Interface, err
|
|||
}
|
||||
|
||||
var pr *api.PullRequest
|
||||
if f.prNumber > 0 {
|
||||
if f.prNumber > 0 || f.branchName == "" {
|
||||
if numberFieldOnly {
|
||||
// avoid hitting the API if we already have all the information
|
||||
return &api.PullRequest{Number: f.prNumber}, f.baseRefRepo, nil
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue