MCPcopy Create free account
hub / github.com/Facets-cloud/flow / NullIfEmpty

Function NullIfEmpty

internal/flowdb/db.go:218–223  ·  view source on GitHub ↗

NullIfEmpty returns a *string pointing to s, or nil if s is empty.

(s string)

Source from the content-addressed store, hash-verified

216
217// NullIfEmpty returns a *string pointing to s, or nil if s is empty.
218func NullIfEmpty(s string) any {
219 if s == "" {
220 return nil
221 }
222 return s
223}
224
225// OpenDB opens (or creates) the SQLite database at path, ensures the
226// schema is present, and runs idempotent migrations.

Callers 1

UpsertWorkdirFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected