@@ -40,10 +40,10 @@ type Platform struct {
4040 Architecture string // The name of the architecture of this package.
4141 Name string
4242 Category string
43- Releases map [string ]* PlatformRelease // The Releases of this platform, labeled by version.
44- Package * Package `json:"-"`
45- ManuallyInstalled bool // true if the Platform has been installed without the CLI
46- Deprecated bool // true if the Platform has been deprecated
43+ Releases map [semver. NormalizedString ]* PlatformRelease // The Releases of this platform, labeled by version.
44+ Package * Package `json:"-"`
45+ ManuallyInstalled bool // true if the Platform has been installed without the CLI
46+ Deprecated bool // true if the Platform has been deprecated
4747}
4848
4949// PlatformReleaseHelp represents the help URL for this Platform release
@@ -191,9 +191,9 @@ func (d *MonitorDependency) String() string {
191191// GetOrCreateRelease returns the specified release corresponding the provided version,
192192// or creates a new one if not found.
193193func (platform * Platform ) GetOrCreateRelease (version * semver.Version ) * PlatformRelease {
194- tag := ""
194+ var tag semver. NormalizedString
195195 if version != nil {
196- tag = version .String ()
196+ tag = version .NormalizedString ()
197197 }
198198 if release , ok := platform .Releases [tag ]; ok {
199199 return release
@@ -213,7 +213,7 @@ func (platform *Platform) GetOrCreateRelease(version *semver.Version) *PlatformR
213213// or nil if not found.
214214func (platform * Platform ) FindReleaseWithVersion (version * semver.Version ) * PlatformRelease {
215215 // use as an fmt.Stringer
216- return platform .Releases [version .String ()]
216+ return platform .Releases [version .NormalizedString ()]
217217}
218218
219219// GetLatestRelease returns the latest release of this platform, or nil if no releases
0 commit comments