Skip to content

Commit 1737192

Browse files
committed
format
1 parent 7657c15 commit 1737192

File tree

6 files changed

+5
-8
lines changed

6 files changed

+5
-8
lines changed

client/transport/interface.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,4 +70,3 @@ type JSONRPCResponse struct {
7070
Result json.RawMessage `json:"result,omitempty"`
7171
Error *mcp.JSONRPCErrorDetails `json:"error,omitempty"`
7272
}
73-

client/transport/utils.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,4 @@ func NewJSONRPCResultResponse(id mcp.RequestId, result json.RawMessage) *JSONRPC
2323
ID: id,
2424
Result: result,
2525
}
26-
}
26+
}

mcp/errors.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,4 +83,3 @@ func (e *JSONRPCErrorDetails) AsError() error {
8383

8484
return err
8585
}
86-

mcp/errors_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,6 @@ func TestJSONRPCErrorDetails_AsError_WithPointer(t *testing.T) {
112112
require.True(t, errors.Is(result, ErrMethodNotFound))
113113
}
114114

115-
116115
func TestSentinelErrors(t *testing.T) {
117116
t.Parallel()
118117

mcp/utils_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
package mcp
22

33
import (
4-
"testing"
54
"github.com/stretchr/testify/assert"
6-
"github.com/stretchr/testify/require"
5+
"github.com/stretchr/testify/require"
6+
"testing"
77
)
88

99
func TestParseAnnotations(t *testing.T) {

server/server.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ func (e *requestError) ToJSONRPCError() mcp.JSONRPCError {
124124
return mcp.JSONRPCError{
125125
JSONRPC: mcp.JSONRPC_VERSION,
126126
ID: mcp.NewRequestId(e.id),
127-
Error: mcp.NewJSONRPCErrorDetails(e.code, e.err.Error(), nil),
127+
Error: mcp.NewJSONRPCErrorDetails(e.code, e.err.Error(), nil),
128128
}
129129
}
130130

@@ -1215,6 +1215,6 @@ func createErrorResponse(
12151215
return mcp.JSONRPCError{
12161216
JSONRPC: mcp.JSONRPC_VERSION,
12171217
ID: mcp.NewRequestId(id),
1218-
Error: mcp.NewJSONRPCErrorDetails(code, message, nil),
1218+
Error: mcp.NewJSONRPCErrorDetails(code, message, nil),
12191219
}
12201220
}

0 commit comments

Comments
 (0)