MCPcopy Create free account
hub / github.com/CreminiAI/skillpack / normalizeJobCron

Function normalizeJobCron

src/job-schedule.ts:3–10  ·  view source on GitHub ↗
(cron: string | undefined | null)

Source from the content-addressed store, hash-verified

1import type { ScheduledJobConfig } from "./job-config.js";
2
3export function normalizeJobCron(cron: string | undefined | null): string | undefined {
4 if (typeof cron !== "string") {
5 return undefined;
6 }
7
8 const normalized = cron.trim();
9 return normalized ? normalized : undefined;
10}
11
12export function hasJobSchedule(
13 jobOrCron: Pick<ScheduledJobConfig, "cron"> | string | undefined | null,

Callers 4

hasJobScheduleFunction · 0.85
registerJobMethod · 0.85
createCronTaskMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected