otter-space-sdk/internal/utils/slices.go
SoXX 34c001473b
Some checks failed
Gitea Build Check / Build (push) Failing after 11m27s
migration from old git (no git history)
2024-07-19 10:03:35 +02:00

12 lines
159 B
Go

package utils
func GetOrDefault(data map[string]any, key string, defaultVal any) any {
val, ok := data[key]
if !ok {
return defaultVal
}
return val
}