Add currency pair display method to display a currency pair based on user config preferences (e.g BTC-USD or BTCUSD)

This commit is contained in:
Adrian Gallagher
2017-08-23 14:02:09 +10:00
parent f684b4d19f
commit 7be8c0272b
24 changed files with 142 additions and 25 deletions

View File

@@ -30,7 +30,7 @@ func (l *LakeBTC) Run() {
log.Println(err)
continue
}
log.Printf("LakeBTC BTC %s: Last %f High %f Low %f Volume %f\n", x[3:], ticker.Last, ticker.High, ticker.Low, ticker.Volume)
log.Printf("LakeBTC %s: Last %f High %f Low %f Volume %f\n", exchange.FormatCurrency(currency).String(), ticker.Last, ticker.High, ticker.Low, ticker.Volume)
stats.AddExchangeInfo(l.GetName(), currency.GetFirstCurrency().String(), currency.GetSecondCurrency().String(), ticker.Last, ticker.Volume)
}
time.Sleep(time.Second * l.RESTPollingDelay)