diff options
| author | Kujtim Hoxha <[email protected]> | 2025-04-14 11:08:17 +0200 |
|---|---|---|
| committer | Kujtim Hoxha <[email protected]> | 2025-04-21 13:41:27 +0200 |
| commit | 921f5ee5bd74837ff4566fc2d1e45051c87d9c38 (patch) | |
| tree | 4d8e20f5b1ee8fc2c99adbcedb400d6657e8f1ef /internal/llm/tools/diagnostics.go | |
| parent | 9ae05fea12ad05ea356a057f67afdde46d548843 (diff) | |
| download | opencode-921f5ee5bd74837ff4566fc2d1e45051c87d9c38.tar.gz opencode-921f5ee5bd74837ff4566fc2d1e45051c87d9c38.zip | |
handle errors correctly in the edit tool
Diffstat (limited to 'internal/llm/tools/diagnostics.go')
| -rw-r--r-- | internal/llm/tools/diagnostics.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/llm/tools/diagnostics.go b/internal/llm/tools/diagnostics.go index 1bb02098e..b7b2bb8ba 100644 --- a/internal/llm/tools/diagnostics.go +++ b/internal/llm/tools/diagnostics.go @@ -82,7 +82,7 @@ func (b *diagnosticsTool) Run(ctx context.Context, call ToolCall) (ToolResponse, waitForLspDiagnostics(ctx, params.FilePath, lsps) } - output := appendDiagnostics(params.FilePath, lsps) + output := getDiagnostics(params.FilePath, lsps) return NewTextResponse(output), nil } @@ -154,7 +154,7 @@ func hasDiagnosticsChanged(current, original map[protocol.DocumentUri][]protocol return false } -func appendDiagnostics(filePath string, lsps map[string]*lsp.Client) string { +func getDiagnostics(filePath string, lsps map[string]*lsp.Client) string { fileDiagnostics := []string{} projectDiagnostics := []string{} |
