mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-16 20:13:52 +00:00
20 lines
352 B
Go
20 lines
352 B
Go
package bitget
|
|
|
|
import "github.com/c9s/bbgo/pkg/util"
|
|
|
|
type LogFunction func(msg string, args ...interface{})
|
|
|
|
var debugf LogFunction
|
|
|
|
func getDebugFunction() LogFunction {
|
|
if v, ok := util.GetEnvVarBool("DEBUG_BITGET"); ok && v {
|
|
return log.Infof
|
|
}
|
|
|
|
return func(msg string, args ...interface{}) {}
|
|
}
|
|
|
|
func init() {
|
|
debugf = getDebugFunction()
|
|
}
|