Skip to content

Commit 9ee5ef7

Browse files
committed
internal/jsonrpc2: remove Direction
It is no longer used after the changes to the logging system. Change-Id: I7b96fb8297eb66f2ebad67c74c82fa7ed96c3139 Reviewed-on: https://go-review.googlesource.com/c/tools/+/227485 Run-TryBot: Ian Cottrell <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Robert Findley <[email protected]>
1 parent 888a00f commit 9ee5ef7

File tree

1 file changed

+0
-22
lines changed

1 file changed

+0
-22
lines changed

internal/jsonrpc2/handler.go

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -18,28 +18,6 @@ import (
1818
// The handler should return ErrNotHandled if it could not handle the request.
1919
type Handler func(context.Context, *Request) error
2020

21-
// Direction is used to indicate to a logger whether the logged message was being
22-
// sent or received.
23-
type Direction bool
24-
25-
const (
26-
// Send indicates the message is outgoing.
27-
Send = Direction(true)
28-
// Receive indicates the message is incoming.
29-
Receive = Direction(false)
30-
)
31-
32-
func (d Direction) String() string {
33-
switch d {
34-
case Send:
35-
return "send"
36-
case Receive:
37-
return "receive"
38-
default:
39-
panic("unreachable")
40-
}
41-
}
42-
4321
// MethodNotFound is a Handler that replies to all call requests with the
4422
// standard method not found response.
4523
// This should normally be the final handler in a chain.

0 commit comments

Comments
 (0)