stephenhaunts / ProfanityDetector

This is a simple library for detecting profanities within a text string.
MIT License
144 stars 29 forks source link

CensorString fails to clean words in multi-line input #22

Open kHackett opened 3 years ago

kHackett commented 3 years ago

In a multi-line textbox entry, words are missed if they are before or after a \r\n or \n. Example: only the first word is censored

var output = profanityFilter.CensorString( "fuk fuk\r\nfuk fuk\nfuk", '#');

kHackett commented 3 years ago

... and also HTML tags eg: "<b>fuk</b>"