refactoring_v1 (#391)

This commit is contained in:
GPT10
2024-08-27 17:04:36 +03:00
committed by GitHub
parent 68c9ed359c
commit 8fe8e614ac
30 changed files with 41777 additions and 38400 deletions

View File

@@ -39,7 +39,11 @@ export const prepareCommitMessageHook = async (
const config = getConfig();
if (!config?.OCO_OPENAI_API_KEY && !config?.OCO_ANTHROPIC_API_KEY && !config?.OCO_AZURE_API_KEY) {
if (
!config.OCO_OPENAI_API_KEY &&
!config.OCO_ANTHROPIC_API_KEY &&
!config.OCO_AZURE_API_KEY
) {
throw new Error(
'No OPEN_AI_API or OCO_ANTHROPIC_API_KEY or OCO_AZURE_API_KEY exists. Set your key in ~/.opencommit'
);