Skip to content

Commit

Permalink
normalize public url (#3627)
Browse files Browse the repository at this point in the history
  • Loading branch information
mastercactapus authored Jan 25, 2024
1 parent ba9df2d commit 91b7233
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -676,6 +676,8 @@ func getConfig(ctx context.Context) (Config, error) {
if u.Scheme == "" {
return cfg, errors.New("public-url must be an absolute URL (missing scheme)")
}
u.Path = strings.TrimSuffix(u.Path, "/")
cfg.PublicURL = u.String()
if cfg.HTTPPrefix != "" {
return cfg, errors.New("public-url and http-prefix cannot be used together")
}
Expand Down

0 comments on commit 91b7233

Please sign in to comment.