tbonelee commented on code in PR #5075:
URL: https://github.com/apache/zeppelin/pull/5075#discussion_r2355558848


##########
zeppelin-web-angular/src/app/visualizations/table/table-visualization.component.ts:
##########
@@ -96,11 +89,8 @@ export class TableVisualizationComponent implements OnInit {
     this.filterRows();
   }
 
-  onSortChange(type: 'descend' | 'ascend' | string, key: string): void {
-    const opt = this.colOptions.get(key);
-    if (!opt) {
-      throw new Error('opt is not found');
-    }
+  onSortChange(type: 'descend' | 'ascend' | string | null, key: string): void {

Review Comment:
   I tried your suggestion, but `nzSortChange` emits an event of following 
type, so the handler needs to accept `null`
   ```
   export declare type NzTableSortOrder = string | 'ascend' | 'descend' | null;
   ```
   Instead, I imported this type and used it in `onSortChange`. What do you 
think?



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to