Skip to content

Commit ca1cd5e

Browse files
committed
fix usage of fmt.Errorf
1 parent 31861bf commit ca1cd5e

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

internal/mcp/mcp_parse.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ package mcp
44
import (
55
_ "embed"
66
"encoding/json"
7-
"fmt"
87
"strings"
98

109
"github.com/sourcegraph/sourcegraph/lib/errors"
@@ -159,7 +158,7 @@ func (p *decoder) decodeProperties(props map[string]json.RawMessage) map[string]
159158
for name, raw := range props {
160159
var r RawSchema
161160
if err := json.Unmarshal(raw, &r); err != nil {
162-
p.errors = append(p.errors, fmt.Errorf("failed to parse property %q: %w", name, err))
161+
p.errors = append(p.errors, errors.Newf("failed to parse property %q: %w", name, err))
163162
continue
164163
}
165164
res[name] = p.decodeSchema(&r)

0 commit comments

Comments
 (0)