fix(version): version range || can has no space

From Matt's comment

> The check for " || " should remove the spaces and have "||". Spaces around the || aren't required.

Signed-off-by: Benoit Tigeot <benoit.tigeot@lifen.fr>
This commit is contained in:
Benoit Tigeot 2026-02-04 22:02:19 +01:00
parent bf78b876c7
commit b79d7f1881
No known key found for this signature in database
GPG key ID: 8E6D4FC8AEBDA62C

View file

@ -178,7 +178,7 @@ func (i IndexFile) SortEntries() {
// isVersionRange checks if the version string is a range constraint (e.g., "^1", "~1.10")
// rather than an exact version (e.g., "1.10.0").
func isVersionRange(version string) bool {
return strings.ContainsAny(version, "^~<>=!*xX") || strings.Contains(version, " || ") || strings.Contains(version, " - ")
return strings.ContainsAny(version, "^~<>=!*xX") || strings.Contains(version, "||") || strings.Contains(version, " - ")
}
// Get returns the ChartVersion for the given name.