mirror of
https://github.com/go-gitea/gitea
synced 2025-07-05 10:07:22 +00:00
Handle submodules without a .gitmodules entry - fix #1023
This commit is contained in:
@ -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
|
||||
|
Reference in New Issue
Block a user