(error: any)
| 705 | job, |
| 706 | `临时管理员到期自动解除失败, 已重试 ${maxExpiryRetries} 次: ${codeTag( |
| 707 | error?.message || error |
| 708 | )}` |
| 709 | ); |
| 710 | return; |
| 711 | } |
| 712 | |
| 713 | job.retryCount += 1; |
| 714 | void this.persistJobQuiet(key, job); |
| 715 | console.error( |
| 716 | `[tmp_admin] 临时管理员到期解除失败, ${expiryRetryDelayMs / 1000}s 后重试 ${key} (${job.retryCount}/${maxExpiryRetries}):`, |
| 717 | error |
| 718 | ); |
| 719 | this.jobs.set(key, job); |
| 720 | scheduleWithDelay(expiryRetryDelayMs); |
| 721 | }; |
| 722 | |
| 723 | const scheduleNext = () => { |
| 724 | const delay = Math.max(0, job.expiresAt - Date.now()); |
| 725 | scheduleWithDelay(delay); |
| 726 | }; |
| 727 | |
| 728 | this.jobs.set(key, job); |
| 729 | scheduleNext(); |
| 730 | } |
| 731 |
nothing calls this directly
no test coverage detected