vogievetsky commented on a change in pull request #9500: Update
druid-query-toolkit to version 4.0
URL: https://github.com/apache/druid/pull/9500#discussion_r390620414
##########
File path: web-console/src/views/query-view/query-output/query-output.tsx
##########
@@ -239,12 +239,14 @@ export const QueryOutput = React.memo(function
QueryOutput(props: QueryOutputPro
const sorted = parsedQuery.getSorted();
if (sorted) {
className.push(
- sorted.map(sorted => {
- if (sorted.id === header) {
- return sorted.desc ? '-sort-desc' : '-sort-asc';
- }
- return '';
- })[0],
+ sorted
+ .map(sorted => {
+ if (sorted.id === header) {
+ return sorted.desc ? '-sort-desc' : '-sort-asc';
+ }
+ return '';
+ })
+ .join(''),
Review comment:
This definitely does not make sense this could create classes like
`-sort-desc-sort-asc`
The existing code probably does not make sense either as it will add the
`undefined` class.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]