ConsoleTVs / Profanity

PHP library to block bad words in a string
MIT License
98 stars 46 forks source link

fix issue #15 #16

Closed ariaieboy closed 11 months ago

ariaieboy commented 4 years ago

so i described the kashida character problem in issue #15

i searched alot about this issue since there is no ignoring character in regex patterns and i dont want to add more complexity to the code i decide to fix this issue by changing the dictionary of the package

so what did i do to fix this issue ? since we use regex pattern for detecting bad words i add the \u0640* after each character of the persian and arabic words in dictionary using the dictionary generator script

and this will match any word that use kashida character between its actual characters