소스 검색

add all channel filter

Joyit 1 개월 전
부모
커밋
a817e5d80d
1개의 변경된 파일7개의 추가작업 그리고 0개의 파일을 삭제
  1. 7 0
      filter.go

+ 7 - 0
filter.go

@@ -5,6 +5,13 @@ import (
 	"strings"
 )
 
+// 匹配所有的频道
+func AllChannelFilter() FilterFunc {
+	return func(conn *Line) (ok bool) {
+		return true
+	}
+}
+
 // 正则频道过滤器
 func RegChannelFilter(channel *regexp.Regexp) FilterFunc {
 	return func(conn *Line) (ok bool) {