MCPcopy Create free account
hub / github.com/GongShichen/LuminaCode / optionalString

Function optionalString

skills/models.go:114–123  ·  view source on GitHub ↗
(value any)

Source from the content-addressed store, hash-verified

112}
113
114func optionalString(value any) *string {
115 if value == nil {
116 return nil
117 }
118 text := strings.TrimSpace(fmt.Sprint(value))
119 if text == "" {
120 return nil
121 }
122 return &text
123}
124
125func coerceModel(value any) *string {
126 result := optionalString(value)

Callers 2

ValidateFrontmatterFunction · 0.85
coerceModelFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected