Skip to content

Commit

Permalink
clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
qvalentin committed May 8, 2024
1 parent f47e51b commit 24a490c
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 65 deletions.
2 changes: 1 addition & 1 deletion internal/adapter/yamlls/completion.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
lsp "go.lsp.dev/protocol"
)

func (yamllsConnector *Connector) CallCompletion(ctx context.Context, params *lsp.CompletionParams) (*lsp.CompletionList, error) {
func (yamllsConnector Connector) CallCompletion(ctx context.Context, params *lsp.CompletionParams) (*lsp.CompletionList, error) {
if yamllsConnector.server == nil {
return &lsp.CompletionList{}, nil
}
Expand Down
2 changes: 1 addition & 1 deletion internal/adapter/yamlls/hover_integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ func TestYamllsHoverIntegration(t *testing.T) {
},
}, tt.word)
return err == nil && strings.Contains(result.Contents.Value, tt.expected)
}, time.Second*60, time.Second*5)
}, time.Second*10, time.Second*2)
})
}
}
5 changes: 3 additions & 2 deletions internal/charts/chart.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,9 @@ func (c *Chart) ResolveValueFiles(query []string, chartStore *ChartStore) []*Que
}

func (c *Chart) GetValueLocation(templateContext []string) (lsp.Location, error) {
modifyedVar := make([]string, 0)
// for Charts, we make the first letter lowercase
modifyedVar := make([]string, len(templateContext))
// make the first letter lowercase since in the template the first letter is
// capitalized, but it is not in the Chart.yaml file
for _, value := range templateContext {
restOfString := ""
if (len(value)) > 1 {
Expand Down
3 changes: 1 addition & 2 deletions internal/handler/generic_document_usecase.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,10 @@ func (h *langHandler) NewGenericDocumentUseCase(
}

var (
parentNodeType string
nodeType = node.Type()
parentNode = node.Parent()
parentNodeType string
)

if parentNode != nil {
parentNodeType = parentNode.Type()
}
Expand Down
59 changes: 0 additions & 59 deletions internal/util/yaml_path.go

This file was deleted.

0 comments on commit 24a490c

Please sign in to comment.