Skip to content

Commit

Permalink
fixed linting error
Browse files Browse the repository at this point in the history
  • Loading branch information
BabyElias committed Dec 7, 2024
1 parent a1f07b0 commit e7e7725
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions lib/KTable/useSorting/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,19 @@ export default function useSorting(headers, rows, defaultSort, disableBuiltinSor
);
}

return _.orderBy(rows.value, [row => {
const value = row[sortKey.value];
if (typeof value === 'string') {
return value.toString().toLocaleLowerCase();
}
return value;
}], [sortOrder.value]);
return _.orderBy(
rows.value,
[
row => {
const value = row[sortKey.value];
if (typeof value === 'string') {
return value.toString().toLocaleLowerCase();
}
return value;
},
],
[sortOrder.value]
);
});

/**
Expand Down Expand Up @@ -91,4 +97,4 @@ export default function useSorting(headers, rows, defaultSort, disableBuiltinSor
handleSort,
getAriaSort,
};
}
}

0 comments on commit e7e7725

Please sign in to comment.