Skip to content

Commit

Permalink
Fix CoinbasePro websocket bug introduced in PR thrasher-corp#262 (thr…
Browse files Browse the repository at this point in the history
  • Loading branch information
xtda authored and thrasher- committed Apr 3, 2019
1 parent 866efd0 commit a0e2910
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions exchanges/coinbasepro/coinbasepro_websocket.go
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ func (c *CoinbasePro) WsHandleData() {

// ProcessSnapshot processes the initial orderbook snap shot
func (c *CoinbasePro) ProcessSnapshot(snapshot *WebsocketOrderbookSnapshot) error {
var base *orderbook.Base
var base orderbook.Base
for _, bid := range snapshot.Bids {
price, err := strconv.ParseFloat(bid[0].(string), 64)
if err != nil {
Expand Down Expand Up @@ -234,7 +234,7 @@ func (c *CoinbasePro) ProcessSnapshot(snapshot *WebsocketOrderbookSnapshot) erro
base.AssetType = "SPOT"
base.Pair = pair

err := c.Websocket.Orderbook.LoadSnapshot(base, c.GetName(), false)
err := c.Websocket.Orderbook.LoadSnapshot(&base, c.GetName(), false)
if err != nil {
return err
}
Expand Down

0 comments on commit a0e2910

Please sign in to comment.