修改热登录错误处理 🚑 (#166)

This commit is contained in:
多吃点苹果 2022-12-14 00:12:44 +08:00 committed by GitHub
parent df01bfefe5
commit 8c9d36ec16
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

5
bot.go
View File

@ -85,9 +85,12 @@ func (b *Bot) HotLogin(storage HotReloadStorage, retries ...bool) error {
if !ok {
return err
}
if retErr == cookieInvalid {
// TODO add more error code handle here
switch retErr {
case cookieInvalid:
return b.Login()
}
return err
}
}
return err