mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-22 06:53:52 +00:00
okex: rename constant names
This commit is contained in:
parent
5f8bda7d72
commit
f942f7afd8
|
@ -17,11 +17,13 @@ import (
|
||||||
|
|
||||||
var marketDataLimiter = rate.NewLimiter(rate.Every(time.Second/10), 1)
|
var marketDataLimiter = rate.NewLimiter(rate.Every(time.Second/10), 1)
|
||||||
|
|
||||||
// OKB is the platform currency of OKEx, pre-allocate static string here
|
const ID = "okex"
|
||||||
const OKB = "OKB"
|
|
||||||
|
// PlatformToken is the platform currency of OKEx, pre-allocate static string here
|
||||||
|
const PlatformToken = "OKB"
|
||||||
|
|
||||||
var log = logrus.WithFields(logrus.Fields{
|
var log = logrus.WithFields(logrus.Fields{
|
||||||
"exchange": "okex",
|
"exchange": ID,
|
||||||
})
|
})
|
||||||
|
|
||||||
type Exchange struct {
|
type Exchange struct {
|
||||||
|
@ -38,8 +40,7 @@ func New(key, secret, passphrase string) *Exchange {
|
||||||
}
|
}
|
||||||
|
|
||||||
return &Exchange{
|
return &Exchange{
|
||||||
key: key,
|
key: key,
|
||||||
// pragma: allowlist nextline secret
|
|
||||||
secret: secret,
|
secret: secret,
|
||||||
passphrase: passphrase,
|
passphrase: passphrase,
|
||||||
client: client,
|
client: client,
|
||||||
|
@ -131,7 +132,7 @@ func (e *Exchange) QueryTickers(ctx context.Context, symbols ...string) (map[str
|
||||||
}
|
}
|
||||||
|
|
||||||
func (e *Exchange) PlatformFeeCurrency() string {
|
func (e *Exchange) PlatformFeeCurrency() string {
|
||||||
return OKB
|
return PlatformToken
|
||||||
}
|
}
|
||||||
|
|
||||||
func (e *Exchange) QueryAccount(ctx context.Context) (*types.Account, error) {
|
func (e *Exchange) QueryAccount(ctx context.Context) (*types.Account, error) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user