# Censored pattern

**URL:** <https://meta.discourse.org/t/censored-pattern/66912>\
**Category:** Bug\
**Created:** [July 27, 2017, 9:40am UTC](https://meta.discourse.org/t/censored-pattern/66912 "2017-07-27T09:40:35Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)\
**Post date:** [July 28, 2017, 3:21pm UTC](https://meta.discourse.org/t/censored-pattern/66912/2 "2017-07-28T15:21:07Z")

</div>

This does not look like a regression, I think it never worked:

[This regex](https://github.com/discourse/discourse/blob/master/app/assets/javascripts/pretty-text/censored-words.js.es6#L23) does not work with Cyrillic .

Anyone have any ideas on how to rewrite:

```plaintext
censorRegexp = new RegExp("(\\b(?:(hello)|(Здравствуйте))\\b)(?![^\\(]*\\))", "ig");

```

So it does not use `\b` which is unsupported Russian.

(be sure to reply here with a tested regex I have already seen the posts on Stack Overflow)

---

_[View the full topic](https://meta.discourse.org/t/censored-pattern/66912)._
