forked from forgejo/forgejo
Handle submodules without a .gitmodules entry - fix #1023
This commit is contained in:
parent
5e763baa12
commit
5d5d774e03
4 changed files with 15 additions and 3 deletions
|
@ -31,6 +31,10 @@ func NewSubModuleFile(c *Commit, refUrl, refId string) *SubModuleFile {
|
|||
|
||||
// RefUrl guesses and returns reference URL.
|
||||
func (sf *SubModuleFile) RefUrl() string {
|
||||
if sf.refUrl == "" {
|
||||
return ""
|
||||
}
|
||||
|
||||
url := strings.TrimSuffix(sf.refUrl, ".git")
|
||||
|
||||
// git://xxx/user/repo
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue