Skip to content

Commit ddbe650

Browse files
committed
bug fix
1 parent 9d30bf4 commit ddbe650

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lists/arrayList.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -101,12 +101,12 @@ func (list *ArrayList) Clear() {
101101
}
102102

103103
// sort the elements by comparator
104-
func (list *ArrayList) Sort(compartors ...container.CompareFunction) {
105-
if len(compartors) == 0 {
104+
func (list *ArrayList) Sort(comparators ...container.CompareFunction) {
105+
if len(comparators) == 0 {
106106
sort.Sort(list)
107107
}
108108

109-
compartor := compartors[0]
109+
compartor := comparators[0]
110110
list.compareFunc = compartor
111111

112112
sort.Sort(list)

0 commit comments

Comments
 (0)