修复企业版身份认证可能会导致异常退出的问题

This commit is contained in:
刘祥超
2021-07-22 10:45:23 +08:00
parent 0fe2bc4a54
commit c954910728
2 changed files with 4 additions and 4 deletions

View File

@@ -74,6 +74,10 @@ func (this *AuthorityTask) Loop() error {
if err != nil {
return err
}
if resp.AuthorityKey == nil {
teaconst.IsPlus = false
return nil
}
var oldState = teaconst.IsPlus
if resp.AuthorityKey != nil && len(resp.AuthorityKey.Value) > 0 && resp.AuthorityKey.DayTo >= timeutil.Format("Y-m-d") {
teaconst.IsPlus = true