mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-04-19 12:12:42 +02:00
add URL encoding in pull request branch names
This commit is contained in:
parent
b70075eba6
commit
ae18ad5b66
@ -4,6 +4,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"regexp"
|
"regexp"
|
||||||
"strings"
|
"strings"
|
||||||
|
"net/url"
|
||||||
|
|
||||||
"github.com/go-errors/errors"
|
"github.com/go-errors/errors"
|
||||||
"github.com/jesseduffield/lazygit/pkg/i18n"
|
"github.com/jesseduffield/lazygit/pkg/i18n"
|
||||||
@ -42,9 +43,9 @@ func (self *HostingServiceMgr) GetPullRequestURL(from string, to string) (string
|
|||||||
}
|
}
|
||||||
|
|
||||||
if to == "" {
|
if to == "" {
|
||||||
return gitService.getPullRequestURLIntoDefaultBranch(from), nil
|
return gitService.getPullRequestURLIntoDefaultBranch(url.QueryEscape(from)), nil
|
||||||
} else {
|
} else {
|
||||||
return gitService.getPullRequestURLIntoTargetBranch(from, to), nil
|
return gitService.getPullRequestURLIntoTargetBranch(url.QueryEscape(from), url.QueryEscape(to)), nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user