Skip to content

Commit

Permalink
Makes go lint happy
Browse files Browse the repository at this point in the history
  • Loading branch information
ksysoev committed Apr 7, 2024
1 parent f90ef88 commit dbbe64c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 2 additions & 1 deletion connection.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,13 @@ type Connection interface {
// Conn is default implementation of Connection
type Conn struct {
ws *websocket.Conn
reqWG *sync.WaitGroup
ctx context.Context
onMessageCB OnMessage
onClose chan<- string
ctxCancel context.CancelFunc
id string
isClosed atomic.Bool
reqWG *sync.WaitGroup
}

// OnMessage is type for OnMessage callback
Expand Down Expand Up @@ -154,6 +154,7 @@ func (c *Conn) HandleRequests() {
}

c.reqWG.Add(1)

go func(wg *sync.WaitGroup) {
defer wg.Done()
c.onMessageCB(c, data)
Expand Down
1 change: 0 additions & 1 deletion middleware/request/throttler.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ func NewTrottlerMiddleware(limit uint) func(next wasabi.RequestHandler) wasabi.R

return func(next wasabi.RequestHandler) wasabi.RequestHandler {
return wasabi.RequestHandlerFunc(func(conn wasabi.Connection, req wasabi.Request) error {

select {
case sem <- token{}:
defer func() { <-sem }()
Expand Down

0 comments on commit dbbe64c

Please sign in to comment.