fix: reduce global react doctor warnings (#214)

This commit is contained in:
Eyejoker
2026-06-03 08:30:24 +08:00
committed by GitHub
parent 22602da1ec
commit 2dab27f443
5 changed files with 41 additions and 45 deletions

View File

@@ -116,19 +116,23 @@ export function suspendTask(taskId: string, suspendedUntil: string): void {
/**
* Format the suspension notification for Discord.
*/
const SUSPENSION_RESUME_FORMATTER = new Intl.DateTimeFormat('ko-KR', {
month: 'numeric',
day: 'numeric',
hour: '2-digit',
minute: '2-digit',
hour12: false,
timeZone: TIMEZONE,
});
export function formatSuspensionNotice(
task: ScheduledTask,
suspendedUntil: string,
reason: string,
): string {
const resumeLabel = new Intl.DateTimeFormat('ko-KR', {
month: 'numeric',
day: 'numeric',
hour: '2-digit',
minute: '2-digit',
hour12: false,
timeZone: TIMEZONE,
}).format(new Date(suspendedUntil));
const resumeLabel = SUSPENSION_RESUME_FORMATTER.format(
new Date(suspendedUntil),
);
const lines = [
`⏸ 태스크 일시 중단`,