MCPcopy Create free account
hub / github.com/1Panel-dev/1Panel / firstAllowedOrigin

Function firstAllowedOrigin

agent/app/service/agents_utils.go:552–560  ·  view source on GitHub ↗
(allowedOrigins []string)

Source from the content-addressed store, hash-verified

550}
551
552func firstAllowedOrigin(allowedOrigins []string) string {
553 for _, origin := range allowedOrigins {
554 trimmed := strings.TrimSpace(origin)
555 if trimmed != "" {
556 return trimmed
557 }
558 }
559 return ""
560}
561
562func buildOpenclawAllowedOrigin(scheme, host string, port int) (string, error) {
563 scheme = strings.TrimSpace(strings.ToLower(scheme))

Callers 3

CreateMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected