增加U盘登录
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
. "code.hoteas.com/golang/hotime"
|
||||
. "code.hoteas.com/golang/hotime/common"
|
||||
"time"
|
||||
"unicode/utf8"
|
||||
)
|
||||
|
||||
// Project 管理端项目
|
||||
@@ -33,3 +34,15 @@ func getCode() string {
|
||||
//}
|
||||
return res
|
||||
}
|
||||
|
||||
// 过滤 emoji 表情
|
||||
func FilterEmoji(content string) string {
|
||||
new_content := ""
|
||||
for _, value := range content {
|
||||
_, size := utf8.DecodeRuneInString(string(value))
|
||||
if size <= 3 {
|
||||
new_content += string(value)
|
||||
}
|
||||
}
|
||||
return new_content
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user