Transit-Talk
Transit-Talk copied to clipboard
Add Language Filters to Issue Reporting
Detailed Description
We need to make a system to prevent user's from submitting content with bad language.
Context
We want to prevent users from submitting data with bad language, which would then require manual moderation. To reduce moderation load, language filters will prevent content being made this is obviously bad.
Possible Implementation
We can get an array of foul words, and reject any content that contains those words.
A quick search indicates there aren't any good gems to solve this problem; they are all deprecated or not fully featured. However, a custom active record validation should be fine for this. See this Ruby Guides section and this StackOverflow answer.