@@ -85,7 +85,7 @@ func handleAliyunSmsRecordConsume(msgData []byte) error { | |||||
aliyunSmsSaleCode = msg.Code | aliyunSmsSaleCode = msg.Code | ||||
extra = msg.Extra | extra = msg.Extra | ||||
} | } | ||||
if aliyunSmsSaleCode == "" { | |||||
if aliyunSmsSaleCode == "" || msg.Phone == "" { | |||||
return nil | return nil | ||||
} | } | ||||
err = aliyun.AliyunSendSms(aliyunSmsId, aliyunSmsSecret, msg.Phone, aliyunSmsSignName, aliyunSmsSaleCode, extra) | err = aliyun.AliyunSendSms(aliyunSmsId, aliyunSmsSecret, msg.Phone, aliyunSmsSignName, aliyunSmsSaleCode, extra) | ||||
@@ -38,7 +38,7 @@ func EggFinWithdrawApplyDataConsume(queue md.MqQueue) { | |||||
//2、取出数据进行消费 | //2、取出数据进行消费 | ||||
ch.Qos(1) | ch.Qos(1) | ||||
delivery := ch.Consume(queue.Name, false) | delivery := ch.Consume(queue.Name, false) | ||||
egg_system_rules.Init(cfg.RedisAddr) | |||||
var alipayStruct *InitAlipayStruct | var alipayStruct *InitAlipayStruct | ||||
client, err := InitAlipay(alipayStruct) | client, err := InitAlipay(alipayStruct) | ||||
if err != nil { | if err != nil { | ||||
@@ -48,7 +48,6 @@ func EggFinWithdrawApplyDataConsume(queue md.MqQueue) { | |||||
})) | })) | ||||
return | return | ||||
} | } | ||||
egg_system_rules.Init(cfg.RedisAddr) | |||||
var res amqp.Delivery | var res amqp.Delivery | ||||
var ok bool | var ok bool | ||||
for { | for { | ||||