refactor: trim cron validation exports · openclaw/openclaw@9e5c454
steipete
·
2026-05-02
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -36,7 +36,7 @@ export function resolveRetentionMs(cronConfig?: CronConfig): number | null {
|
36 | 36 | return DEFAULT_RETENTION_MS; |
37 | 37 | } |
38 | 38 | |
39 | | -export type ReaperResult = { |
| 39 | +type ReaperResult = { |
40 | 40 | swept: boolean; |
41 | 41 | pruned: number; |
42 | 42 | }; |
|
| Original file line number | Diff line number | Diff line change |
|---|
|
1 | | -export const INVALID_CRON_SESSION_TARGET_ID_ERROR = "invalid cron sessionTarget session id"; |
| 1 | +const INVALID_CRON_SESSION_TARGET_ID_ERROR = "invalid cron sessionTarget session id"; |
2 | 2 | |
3 | 3 | export function isInvalidCronSessionTargetIdError(error: unknown): boolean { |
4 | 4 | return error instanceof Error && error.message === INVALID_CRON_SESSION_TARGET_ID_ERROR; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -5,16 +5,16 @@ import type { CronSchedule } from "./types.js";
|
5 | 5 | const ONE_MINUTE_MS = 60 * 1000; |
6 | 6 | const TEN_YEARS_MS = 10 * 365.25 * 24 * 60 * 60 * 1000; |
7 | 7 | |
8 | | -export type TimestampValidationError = { |
| 8 | +type TimestampValidationError = { |
9 | 9 | ok: false; |
10 | 10 | message: string; |
11 | 11 | }; |
12 | 12 | |
13 | | -export type TimestampValidationSuccess = { |
| 13 | +type TimestampValidationSuccess = { |
14 | 14 | ok: true; |
15 | 15 | }; |
16 | 16 | |
17 | | -export type TimestampValidationResult = TimestampValidationSuccess | TimestampValidationError; |
| 17 | +type TimestampValidationResult = TimestampValidationSuccess | TimestampValidationError; |
18 | 18 | |
19 | 19 | /** |
20 | 20 | * Validates at timestamps in cron schedules. |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。