mirror of
https://github.com/warmbly/warmbly.git
synced 2026-11-28 08:05:45 +00:00
13 lines
331 B
Go
13 lines
331 B
Go
package config
|
|
|
|
import "net/url"
|
|
|
|
// ReportURLOn is a shared client report's public page on host, or on the shared portal address when host is empty; "" when neither is known.
|
|
func ReportURLOn(host, token string) string {
|
|
base := PortalOriginOn(host)
|
|
if base == "" {
|
|
return ""
|
|
}
|
|
return base + "/r/" + url.PathEscape(token)
|
|
}
|