vogievetsky commented on code in PR #20544:
URL: https://github.com/apache/druid/pull/20544#discussion_r4297117268


##########
web-console/src/utils/table-filters/table-filter.ts:
##########
@@ -64,14 +96,18 @@ export class TableFilter {
     return new TableFilter(filter.id, mode, value);
   }
 
+  /**
+   * @param value the values to filter on, or a needle (as typed in a filter 
input) of values separated by `|` (see
+   * `splitNeedle`). To filter on one literal value, that may contain a `|`, 
pass it as `[value]`.
+   */
   constructor(key: string, mode: FilterMode, value: string | string[]) {
     this.key = key;
     this.mode = mode;
-    this.values = typeof value === 'string' ? value.split('|') : value;
+    this.values = typeof value === 'string' ? TableFilter.splitNeedle(value) : 
value;
   }
 
   public get value(): string {
-    return this.values.join('|');
+    return TableFilter.joinNeedle(this.values);

Review Comment:
   Good catch, fixed in e7bc667479: the segment timeline now gets the filter's 
raw value (`values[0]`), only when there's exactly one.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to