mirror of
https://github.com/tiennm99/ccs.git
synced 2026-10-13 02:14:32 +00:00
fix(hooks): add defensive validation for env var generation
This commit is contained in:
1 parent
70caaa00a0
commit
9662490a74
1 file changed
+2
-2
@@ -25,8 +25,8 @@ export function getImageAnalysisHookEnv(profileName?: string): Record<string, st
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
CCS_IMAGE_ANALYSIS_ENABLED: config.enabled ? '1' : '0',
|
CCS_IMAGE_ANALYSIS_ENABLED: config.enabled ? '1' : '0',
|
||||||
CCS_IMAGE_ANALYSIS_MODEL: config.model,
|
CCS_IMAGE_ANALYSIS_MODEL: config.model || 'gemini-2.5-flash',
|
||||||
CCS_IMAGE_ANALYSIS_TIMEOUT: config.timeout.toString(),
|
CCS_IMAGE_ANALYSIS_TIMEOUT: String(Number(config.timeout) || 60),
|
||||||
CCS_IMAGE_ANALYSIS_PROVIDERS: config.providers.join(','),
|
CCS_IMAGE_ANALYSIS_PROVIDERS: config.providers.join(','),
|
||||||
CCS_IMAGE_ANALYSIS_SKIP: skipImageAnalysis ? '1' : '0',
|
CCS_IMAGE_ANALYSIS_SKIP: skipImageAnalysis ? '1' : '0',
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in new issue
Block a user