Skip to content

Commit b78bf22

Browse files
authored
fix: fix lint issues (#82)
1 parent 96164b7 commit b78bf22

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

lib/formatter.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,9 @@ function sortBy(cb) {
66
return (v1, v2) => {
77
v1 = cb(v1);
88
v2 = cb(v2);
9-
return v1 < v2 ? -1 : v1 > v2 ? 1 : 0;
9+
if (v1 < v2) return -1;
10+
if (v1 > v2) return 1;
11+
return 0;
1012
};
1113
}
1214

@@ -25,8 +27,8 @@ function createSortFunction(positionless, sortByPosition) {
2527
if (sortByPosition) {
2628
return (v1, v2) => (
2729
sortFunction(v1, v2) ||
28-
sortBy((m) => m.line || "")(v1, v2) ||
29-
sortBy((m) => m.column || "")(v1, v2));
30+
sortBy((m) => m.line || '')(v1, v2) ||
31+
sortBy((m) => m.column || '')(v1, v2));
3032
}
3133

3234
return sortFunction;

0 commit comments

Comments
 (0)