From 6af93cd2bd89d38ade8d9384fe3798aed1a38a65 Mon Sep 17 00:00:00 2001 From: Dave Henderson Date: Sat, 4 Feb 2023 20:48:57 -0500 Subject: Remove uses of pkg/errors Signed-off-by: Dave Henderson --- data/datasource_stdin.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'data/datasource_stdin.go') diff --git a/data/datasource_stdin.go b/data/datasource_stdin.go index 4592b209..98fbefb3 100644 --- a/data/datasource_stdin.go +++ b/data/datasource_stdin.go @@ -2,10 +2,9 @@ package data import ( "context" + "fmt" "io" "os" - - "github.com/pkg/errors" ) func readStdin(ctx context.Context, source *Source, args ...string) ([]byte, error) { @@ -13,7 +12,7 @@ func readStdin(ctx context.Context, source *Source, args ...string) ([]byte, err b, err := io.ReadAll(stdin) if err != nil { - return nil, errors.Wrapf(err, "Can't read %s", stdin) + return nil, fmt.Errorf("can't read %s: %w", stdin, err) } return b, nil } -- cgit v1.2.3