From 407f71d2089039908d3e0ae9ecbfa2863a4466be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E5=AD=90=E9=93=AD?= Date: Thu, 21 Nov 2024 09:37:33 +0800 Subject: [PATCH] xxx --- plugins/zltx_v2/internal/vo/account_type.go | 2 -- utils/helper/common.go | 7 ------- 2 files changed, 9 deletions(-) diff --git a/plugins/zltx_v2/internal/vo/account_type.go b/plugins/zltx_v2/internal/vo/account_type.go index c47d093..79457df 100644 --- a/plugins/zltx_v2/internal/vo/account_type.go +++ b/plugins/zltx_v2/internal/vo/account_type.go @@ -15,8 +15,6 @@ func (o AccountType) AccountType(account string) AccountType { return AccountTypeDefault } else if helper.IsPhoneNumber(account) { return AccountTypePhone - } else if helper.IsValidQQ(account) { - return AccountTypeQQ } return AccountTypeDefault } diff --git a/utils/helper/common.go b/utils/helper/common.go index 87baf05..9301fc1 100644 --- a/utils/helper/common.go +++ b/utils/helper/common.go @@ -30,10 +30,3 @@ func IsEmail(email string) bool { var emailRegex = regexp.MustCompile(`[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$`) return emailRegex.MatchString(email) } - -// IsValidQQ 检查给定的字符串是否为有效的 QQ 号 -func IsValidQQ(qq string) bool { - // QQ号正则表达式:5到11位数字,且开头不为0的情况 - re := regexp.MustCompile(`^(?!0)[0-9]{5,11}$`) - return re.MatchString(qq) -}