summaryrefslogtreecommitdiff
path: root/flood.go
diff options
context:
space:
mode:
Diffstat (limited to 'flood.go')
-rw-r--r--flood.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/flood.go b/flood.go
index dd1540f..d7fd05d 100644
--- a/flood.go
+++ b/flood.go
@@ -11,6 +11,7 @@ import (
const (
runes = 6
words = 6
+ black = "\u24B6\u262D\u272F\u262E\u2721\u5350\u534D\u2719\u0FD5\u0FD6\u16CB\u16CB\uA5A6\u0FD7\u0FD8"
)
func entropy(s string) (e float64) {
@@ -25,6 +26,9 @@ func entropy(s string) (e float64) {
}
func isFlood(s string) bool {
+ if strings.ContainsAny(s, black) {
+ return true
+ }
if utf8.RuneCountInString(s) <= runes {
return false
}