Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Banning correct words, such as classroom #101

Open
jagermesh opened this issue Sep 10, 2020 · 5 comments
Open

Banning correct words, such as classroom #101

jagermesh opened this issue Sep 10, 2020 · 5 comments

Comments

@jagermesh
Copy link

[orig] => this is our classroom
[clean] => this is our cl***room
@lukepass
Copy link

I have the same problem, is there a way to match whole words only? Thanks.

@lukepass
Copy link

I saw that you can pass a second argument to censorString and it will match whole words only:

public function censorString($string, $fullWords = false) // <-- defaults to false, you can put true to match whole words

@jagermesh
Copy link
Author

Yeah, but this will start showing other words which are in 99% cases must be hidden. For example f**k must be considered as bad either as part of other word or as separate word, so regardless of the $fullWords true or false.

@harpreetsb
Copy link

same problem with word asshole
if we set fullwords to true, word classroom is passed but then word asshole is also passed.

@rob4226
Copy link

rob4226 commented May 4, 2021

I would still set fullwords to true then add asshole to the dictionary so it will be filtered as a fullword.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants