mirror of
https://github.com/renovatebot/renovate.git
synced 2025-01-12 23:16:26 +00:00
14 lines
381 B
TypeScript
14 lines
381 B
TypeScript
import { RenovateConfig } from '../../config';
|
|
import {
|
|
REPOSITORY_DISABLED,
|
|
REPOSITORY_FORKED,
|
|
} from '../../constants/error-messages';
|
|
|
|
export function checkIfConfigured(config: RenovateConfig): void {
|
|
if (config.enabled === false) {
|
|
throw new Error(REPOSITORY_DISABLED);
|
|
}
|
|
if (config.isFork && !config.includeForks) {
|
|
throw new Error(REPOSITORY_FORKED);
|
|
}
|
|
}
|