gitlab.com/evatix-go/core@v1.3.55/conditional/SetterDefault.go (about) 1 package conditional 2 3 import "gitlab.com/evatix-go/core/issetter" 4 5 func SetterDefault( 6 currentSetter issetter.Value, 7 defVal issetter.Value, 8 ) issetter.Value { 9 if currentSetter.IsUnSetOrUninitialized() { 10 return defVal 11 } 12 13 return currentSetter 14 }