aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/Crocmagnon/fatcontext/pkg
diff options
context:
space:
mode:
authordependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>2024-12-01 01:15:39 +0000
committerTaras Madan <tarasmadan@google.com>2024-12-05 09:05:33 +0000
commit7c3db81921ceea352412011ea6cd8961e7224fb0 (patch)
tree55979369fc4d3319619d0537bc0c1e83dfb7b98f /vendor/github.com/Crocmagnon/fatcontext/pkg
parent29f61fceff5d68b408b9086bff96ca036b503584 (diff)
mod: bump github.com/golangci/golangci-lint from 1.62.0 to 1.62.2
Bumps [github.com/golangci/golangci-lint](https://github.com/golangci/golangci-lint) from 1.62.0 to 1.62.2. - [Release notes](https://github.com/golangci/golangci-lint/releases) - [Changelog](https://github.com/golangci/golangci-lint/blob/master/CHANGELOG.md) - [Commits](https://github.com/golangci/golangci-lint/compare/v1.62.0...v1.62.2) --- updated-dependencies: - dependency-name: github.com/golangci/golangci-lint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
Diffstat (limited to 'vendor/github.com/Crocmagnon/fatcontext/pkg')
-rw-r--r--vendor/github.com/Crocmagnon/fatcontext/pkg/analyzer/analyzer.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/vendor/github.com/Crocmagnon/fatcontext/pkg/analyzer/analyzer.go b/vendor/github.com/Crocmagnon/fatcontext/pkg/analyzer/analyzer.go
index a65efbba8..7b88bf56e 100644
--- a/vendor/github.com/Crocmagnon/fatcontext/pkg/analyzer/analyzer.go
+++ b/vendor/github.com/Crocmagnon/fatcontext/pkg/analyzer/analyzer.go
@@ -59,7 +59,7 @@ func run(pass *analysis.Pass) (interface{}, error) {
{
Pos: assignStmt.Pos(),
End: assignStmt.End(),
- NewText: []byte(suggested),
+ NewText: suggested,
},
},
})
@@ -215,10 +215,10 @@ func getRootIdent(pass *analysis.Pass, node ast.Node) *ast.Ident {
}
// render returns the pretty-print of the given node
-func render(fset *token.FileSet, x interface{}) (string, error) {
+func render(fset *token.FileSet, x interface{}) ([]byte, error) {
var buf bytes.Buffer
if err := printer.Fprint(&buf, fset, x); err != nil {
- return "", fmt.Errorf("printing node: %w", err)
+ return nil, fmt.Errorf("printing node: %w", err)
}
- return buf.String(), nil
+ return buf.Bytes(), nil
}