Files
renovate/lib/workers/repository/configured.ts
Sergei Zharinov 930cf6633c refactor: Rewrite imports with .ts extensions (#40700)
fix: Additional vi.mock path corrections and prettier formatting
2026-01-26 22:48:17 +00:00

15 lines
433 B
TypeScript

import type { RenovateConfig } from '../../config/types.ts';
import {
REPOSITORY_DISABLED_BY_CONFIG,
REPOSITORY_FORKED,
} from '../../constants/error-messages.ts';
export function checkIfConfigured(config: RenovateConfig): void {
if (config.enabled === false) {
throw new Error(REPOSITORY_DISABLED_BY_CONFIG);
}
if (config.isFork && config.forkProcessing !== 'enabled') {
throw new Error(REPOSITORY_FORKED);
}
}