Skip to content

Commit

Permalink
fixing lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
purehyperbole committed Mar 5, 2019
1 parent dc5da77 commit eda8a62
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ func unauthorized(c *websocket.Conn, err error) error {

func getAuthMessage(c *websocket.Conn, s *Session) error {
// timeout after 2 seconds if no request is sent
c.SetReadDeadline(time.Now().Add(time.Second * 5))
_ = c.SetReadDeadline(time.Now().Add(time.Second * 5))

_, message, err := c.ReadMessage()
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,5 +78,5 @@ func upgradefail(w http.ResponseWriter, err error) {
func badrequest(c *websocket.Conn, reqid string, err error) {
log.Printf("[%s] bad request: %s\n", reqid, err.Error())
_ = c.WriteMessage(websocket.CloseUnsupportedData, []byte(`{"error": "bad request"}`))
c.Close()
_ = c.Close()
}

0 comments on commit eda8a62

Please sign in to comment.