Skip to content

Commit

Permalink
ZB: GetOrderbook out of range fix (thrasher-corp#286)
Browse files Browse the repository at this point in the history
ZB: GetOrderbook out of range fix
  • Loading branch information
shazbert authored and thrasher- committed Apr 29, 2019
1 parent 47152c8 commit 88bc17a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions exchanges/zb/zb.go
Original file line number Diff line number Diff line change
Expand Up @@ -285,8 +285,8 @@ func (z *ZB) GetOrderbook(symbol string) (OrderbookResponse, error) {

// reverse asks data
var data [][]float64
for x := len(res.Asks) - 1; x != 0; x-- {
data = append(data, res.Asks[x])
for x := len(res.Asks); x > 0; x-- {
data = append(data, res.Asks[x-1])
}

res.Asks = data
Expand Down

0 comments on commit 88bc17a

Please sign in to comment.