This improves Twitch banned phrases and brings it up to par with link bans.
Before we had a set (albeit configurable) time a user would be timeouted with upon seeing a banned phrase. First of all, it was broken, and used std.algorithm.comparison : equal rather than std.algorithm.searching : canFind to detect the phrase. Second, it only ever repeated that timeout duration.
Now we let it escalate into a hardcoded 5 seconds -> 60 seconds -> 3600 seconds, with some grace periods to stop the user from getting a fresh 5 second ban if they immediately trigger the ban system again once the timeout ends.
This improves Twitch banned phrases and brings it up to par with link bans.
Before we had a set (albeit configurable) time a user would be timeouted with upon seeing a banned phrase. First of all, it was broken, and used
std.algorithm.comparison : equal
rather thanstd.algorithm.searching : canFind
to detect the phrase. Second, it only ever repeated that timeout duration.Now we let it escalate into a hardcoded 5 seconds -> 60 seconds -> 3600 seconds, with some grace periods to stop the user from getting a fresh 5 second ban if they immediately trigger the ban system again once the timeout ends.
Some other commits intermingled.