Apply keyword mutes to reblogs.

This commit is contained in:
David Yip
2017-10-21 15:44:47 -05:00
parent 670e6a33f8
commit ad86c86fa8
4 changed files with 26 additions and 2 deletions

View File

@@ -45,5 +45,9 @@ class Glitch::KeywordMute < ApplicationRecord
def =~(str)
regex ? regex =~ str : false
end
def matches?(str)
!!(regex =~ str)
end
end
end