mirror of
https://github.com/anomalyco/opencode.git
synced 2026-04-29 13:09:46 +00:00
small fixes
This commit is contained in:
parent
cfdd687216
commit
795b369219
7 changed files with 13 additions and 24 deletions
|
|
@ -80,7 +80,7 @@ func (e *editTool) Run(ctx context.Context, call ToolCall) (ToolResponse, error)
|
|||
if err != nil {
|
||||
return NewTextErrorResponse(fmt.Sprintf("error creating file: %s", err)), nil
|
||||
}
|
||||
return NewTextErrorResponse(result), nil
|
||||
return NewTextResponse(result), nil
|
||||
}
|
||||
|
||||
if params.NewString == "" {
|
||||
|
|
@ -88,7 +88,7 @@ func (e *editTool) Run(ctx context.Context, call ToolCall) (ToolResponse, error)
|
|||
if err != nil {
|
||||
return NewTextErrorResponse(fmt.Sprintf("error deleting content: %s", err)), nil
|
||||
}
|
||||
return NewTextErrorResponse(result), nil
|
||||
return NewTextResponse(result), nil
|
||||
}
|
||||
|
||||
result, err := replaceContent(params.FilePath, params.OldString, params.NewString)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue