MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / hasRequestedModelMetadata

Function hasRequestedModelMetadata

sdk/cliproxy/auth/conductor.go:2816–2832  ·  view source on GitHub ↗
(meta map[string]any)

Source from the content-addressed store, hash-verified

2814}
2815
2816func hasRequestedModelMetadata(meta map[string]any) bool {
2817 if len(meta) == 0 {
2818 return false
2819 }
2820 raw, ok := meta[cliproxyexecutor.RequestedModelMetadataKey]
2821 if !ok || raw == nil {
2822 return false
2823 }
2824 switch v := raw.(type) {
2825 case string:
2826 return strings.TrimSpace(v) != ""
2827 case []byte:
2828 return strings.TrimSpace(string(v)) != ""
2829 default:
2830 return false
2831 }
2832}
2833
2834type requestAuthPrepareLock struct {
2835 mu sync.Mutex

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected