INNER CODE UNIT · Go

canFieldTypeBeNil

devtron-labs/devtron · WiringNilCheck.go:84

func canFieldTypeBeNil(field reflect.Value) bool {
	return reflectUtil.IsNullableValue(field)
}

func canSkipFieldStructCheck(fieldName, valName string) bool {
	fieldName = strings.ToLower(fieldName)
	valName = strings.ToLower(valName)
	if valName == "githubclient" && (fieldName == "client" || fieldName == "gitopshelper") {
		return true
	}
	for _, str := range []string{"logger", "dbconnection", "syncedenforcer"} {
		if fieldName == str {
			return true
		}
	}
	return false
}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…