Merge branch 'std-http' into refactor_split-long-funcs

This commit is contained in:
6543 2022-11-12 01:08:24 +01:00
commit 3d9ffcf8d7
No known key found for this signature in database
GPG key ID: B8BE6D610E61C862
9 changed files with 73 additions and 72 deletions

View file

@ -95,7 +95,7 @@ func Handler(mainDomainSuffix, rawDomain string,
// TODO: move into external func to not alert vars indirectly
tryBranch1 := func(log zerolog.Logger, repo, branch string, _path []string, canonicalLink string) bool {
if repo == "" {
log.Debug().Msg("tryBranch: repo == ''")
log.Debug().Msg("tryBranch: repo is empty")
return false
}
@ -213,7 +213,7 @@ func Handler(mainDomainSuffix, rawDomain string,
canonicalDomainCache)
} else {
html.ReturnErrorPage(ctx,
fmt.Sprintf("explizite set branch '%s' do not exist at '%s/%s'", branch, targetOwner, targetRepo),
fmt.Sprintf("explizite set branch %q do not exist at '%s/%s'", branch, targetOwner, targetRepo),
http.StatusFailedDependency)
}
return
@ -232,7 +232,7 @@ func Handler(mainDomainSuffix, rawDomain string,
canonicalDomainCache)
} else {
html.ReturnErrorPage(ctx,
fmt.Sprintf("explizite set branch '%s' do not exist at '%s/%s'", branch, targetOwner, "pages"),
fmt.Sprintf("explizite set branch %q do not exist at '%s/%s'", branch, targetOwner, "pages"),
http.StatusFailedDependency)
}
return