mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-14 07:26:47 +00:00
added gorilla websocket conn and mutex
This commit is contained in:
@@ -8,8 +8,10 @@ import (
|
||||
"reflect"
|
||||
"strconv"
|
||||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/gorilla/websocket"
|
||||
"github.com/thrasher-/gocryptotrader/common"
|
||||
"github.com/thrasher-/gocryptotrader/config"
|
||||
exchange "github.com/thrasher-/gocryptotrader/exchanges"
|
||||
@@ -78,6 +80,8 @@ var errMissValue = errors.New("warning - resp value is missing from exchange")
|
||||
// OKEX is the overaching type across the OKEX methods
|
||||
type OKEX struct {
|
||||
exchange.Base
|
||||
WebsocketConn *websocket.Conn
|
||||
mu sync.Mutex
|
||||
|
||||
// Spot and contract market error codes as per https://www.okex.com/rest_request.html
|
||||
ErrorCodes map[string]error
|
||||
|
||||
Reference in New Issue
Block a user