@ -10,12 +10,13 @@ type Transport struct {
apiKey string // apiKey
}
// args 0: sm4Key, 1: apiKey
func NewTransport(env enum.Env, args ...string) *Transport {
var sm4Key, apiKey string
if len(args) > 1 {
if len(args) > 0 {
sm4Key = args[0]
if len(args) > 2 {
apiKey = args[1]
return &Transport{