Skip to content

Commit

Permalink
Added line sorting back in for GetAllSchemas
Browse files Browse the repository at this point in the history
Signed-off-by: Dave Shanley <dave@quobix.com>
  • Loading branch information
daveshanley committed Aug 9, 2023
1 parent f05abdb commit 976ca09
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions index/spec_index.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ package index

import (
"fmt"
"sort"
"strings"
"sync"

Expand Down Expand Up @@ -245,9 +246,9 @@ func (index *SpecIndex) GetAllSchemas() []*Reference {
combined[i] = refSchemas[x]
i++
}
//sort.Slice(combined, func(i, j int) bool {
// return combined[i].Node.Line < combined[j].Node.Line
//})
sort.Slice(combined, func(i, j int) bool {
return combined[i].Node.Line < combined[j].Node.Line
})
return combined
}

Expand Down

0 comments on commit 976ca09

Please sign in to comment.