mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-22 08:42:32 -05:00
fix: support www.github.com
for migrations
(cherry picked from commit 284ffe4e00
)
This commit is contained in:
parent
d96cef1ac4
commit
0c0fd333f3
1 changed files with 5 additions and 0 deletions
|
@ -45,6 +45,11 @@ func (f *GithubDownloaderV3Factory) New(ctx context.Context, opts base.MigrateOp
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// some users are using the github redirect url for migration
|
||||||
|
if u.Host == "www.github.com" {
|
||||||
|
u.Host = "github.com"
|
||||||
|
}
|
||||||
|
|
||||||
baseURL := u.Scheme + "://" + u.Host
|
baseURL := u.Scheme + "://" + u.Host
|
||||||
fields := strings.Split(u.Path, "/")
|
fields := strings.Split(u.Path, "/")
|
||||||
oldOwner := fields[1]
|
oldOwner := fields[1]
|
||||||
|
|
Loading…
Reference in a new issue