func IsSupportedReleaseBranch()

in cmd/release/utils/values/releasebranch.go [25:38]


func IsSupportedReleaseBranch(rb string) (bool, error) {
	supportedReleaseBranches, err := GetSupportedReleaseBranches()
	if err != nil {
		return false, fmt.Errorf("getting release branches to check if %s is supported: %w", rb, err)
	}

	providedReleaseBranch := []byte(rb)
	for _, supportedReleaseBranch := range supportedReleaseBranches {
		if bytes.Equal(supportedReleaseBranch, providedReleaseBranch) {
			return true, nil
		}
	}
	return false, nil
}