You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I realize your question was quite a while ago, but in case this helps the next person looking here, I was able to add more disallowed words with something like this:
profanity_filter=ProfanityFilter.newprofanity_filter.available_strategies[:custom]=CustomProfanityFilterStrategy.setupprofanity_filter.profane?word,strategies: [:duplicate_characters,:custom]```ruby# You may want to change your base strategy here, depending on your needsclassCustomProfanityFilterStrategy < ProfanityFilterEngine::AllowDuplicateCharactersStrategy# Put all of your words here, or load them from a file somehowDICTIONARY=%w[idiots].freezedefself.setupnew(dictionary: DICTIONARY,ignore_case: true)endend
No description provided.
The text was updated successfully, but these errors were encountered: