Revering change unrelated to issue #13176

Signed-off-by: ricardo.bartels@telekom.de <ricardo.bartels@telekom.de>
pull/13177/head
ricardo.bartels@telekom.de 1 year ago committed by Robert Sirchia
parent af13b0d8dc
commit cdbef2b7d1
No known key found for this signature in database
GPG Key ID: C2D40F4D8196E874

@ -353,10 +353,6 @@ func loadIndex(data []byte, source string) (*IndexFile, error) {
return i, err return i, err
} }
if i.APIVersion == "" {
return i, ErrNoAPIVersion
}
for name, cvs := range i.Entries { for name, cvs := range i.Entries {
for idx := len(cvs) - 1; idx >= 0; idx-- { for idx := len(cvs) - 1; idx >= 0; idx-- {
if cvs[idx] == nil { if cvs[idx] == nil {
@ -379,6 +375,9 @@ func loadIndex(data []byte, source string) (*IndexFile, error) {
i.Entries[name] = cvs i.Entries[name] = cvs
} }
i.SortEntries() i.SortEntries()
if i.APIVersion == "" {
return i, ErrNoAPIVersion
}
return i, nil return i, nil
} }

Loading…
Cancel
Save