Skip to content

Commit

Permalink
No longer escape inline code content for filter lists
Browse files Browse the repository at this point in the history
  • Loading branch information
marvin-roesch committed Mar 12, 2023
1 parent 00832f9 commit fb12fc7
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/cmds/message-filter/filters.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { escape } from '../../utils/message-utils';

export interface MessageFilter {
match (content: string): Array<FilterResult>;

Expand Down Expand Up @@ -35,7 +33,7 @@ export class RegexFilter implements MessageFilter {
}

describe (): string {
return `Matches \`/${escape(this.regex.source)}/\``;
return `Matches \`/${this.regex.source}/\``;
}

toJSON (): SerializedFilter {
Expand All @@ -52,7 +50,7 @@ export class ContainsFilter extends RegexFilter {
}

describe (): string {
return `Contains \`${escape(this.search)}\``;
return `Contains \`${this.search}\``;
}

toJSON (): SerializedFilter {
Expand All @@ -69,7 +67,7 @@ export class WordFilter extends RegexFilter {
}

describe (): string {
return `Contains \`${escape(this.word)}\` surrounded by word boundaries`;
return `Contains \`${this.word}\` surrounded by word boundaries`;
}

toJSON (): SerializedFilter {
Expand Down

0 comments on commit fb12fc7

Please sign in to comment.