mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-19 18:04:41 +00:00
feat(coding-agent): add blockImages setting to prevent image uploads
This commit is contained in:
parent
9063a71fe6
commit
b582a6b70d
9 changed files with 266 additions and 25 deletions
|
|
@ -592,7 +592,13 @@ export class AgentSession {
|
|||
// Add user message
|
||||
const userContent: (TextContent | ImageContent)[] = [{ type: "text", text: expandedText }];
|
||||
if (options?.images) {
|
||||
userContent.push(...options.images);
|
||||
const blockImages = this.settingsManager.getBlockImages();
|
||||
if (blockImages) {
|
||||
// Log warning for blocked images
|
||||
console.warn(`[blockImages] Blocked ${options.images.length} image(s) from being sent to provider`);
|
||||
} else {
|
||||
userContent.push(...options.images);
|
||||
}
|
||||
}
|
||||
messages.push({
|
||||
role: "user",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue