Return if matcher.find() OR matcher.matches() is true since one seems to work when it's the only thing in the text, and the other only works when there is other text around it??
This commit is contained in:
parent
a2aa2d8b94
commit
fc76d07b4c
|
|
@ -44,7 +44,7 @@ public class ChatFilter {
|
||||||
|
|
||||||
public boolean matches(String input) {
|
public boolean matches(String input) {
|
||||||
Matcher matcher = pattern.matcher(input);
|
Matcher matcher = pattern.matcher(input);
|
||||||
return matcher.matches();
|
return (matcher.find() || matcher.matches());
|
||||||
}
|
}
|
||||||
|
|
||||||
public String replaceText(String input) {
|
public String replaceText(String input) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user