Skip to content

Commit a0e3291

Browse files
committed
feat: display login error code
1 parent 069f9d1 commit a0e3291

1 file changed

Lines changed: 1 addition & 7 deletions

File tree

‎cmd/gocq/login.go‎

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -224,13 +224,7 @@ func loginResponseProcessor(res *client.LoginResponse) error {
224224
os.Exit(0)
225225
case client.OtherLoginError, client.UnknownLoginError, client.TooManySMSRequestError:
226226
msg := res.ErrorMessage
227-
if strings.Contains(msg, "冻结") {
228-
log.Warnf("账号被冻结")
229-
log.Infof("按 Enter 继续....")
230-
readLine()
231-
os.Exit(0)
232-
}
233-
log.Warnf("登录失败: %v", msg)
227+
log.Warnf("登录失败: %v Code: %v", msg, res.Code)
234228
log.Infof("按 Enter 继续....")
235229
readLine()
236230
os.Exit(0)

0 commit comments

Comments
 (0)