I’m sorry, but not so fast.
Watched Words Censor now works for words with wildcards.
However, it doesn’t work if watched_words_regular_expression is true.
I don’t think the censor function even considers it as regular expression at all.
Repo:
- Settings > watched words regular expression ==> ON
- Add
xyz*toCensor - In compose window, type
xyz123 - See that it is censored as it is treating the
*as a wildcard. If it is treated as a regular expression,xyz*should only matchxyfollowed by a string ofzzzz…
EDIT: The below is the culprit…
Notice that it is not even considering that the pattern may already be a regular expression.
Also,
This is always assuming that the pattern is a word pattern and \b pairs are auto-wrapped onto it. If the pattern is a regular expression, obviously the \b pairs can be omitted because the user should put them in himself.