Commit 65a9179a by 庄冰

aaa

parent 630d58d2
......@@ -13,9 +13,12 @@ class WxcomponentverifyticketCache extends CacheBase{
this.wxopenplatformconfig = settings.wxopenplatformconfig;
}
async cacheComponentVerifyTicket(value){
console.log("cacheComponentVerifyTicket:value---------------"+value);
var key=this.prefix+this.wxopenplatformconfig.appid;
console.log("cacheComponentVerifyTicket:key---------------"+key);
if(value){
var beforevalue = await this.redisClient.get(key);
console.log("cacheComponentVerifyTicket:beforevalue---------------"+beforevalue);
if(beforevalue!=value){
await this.redisClient.set(key,value);
}
......
......@@ -154,7 +154,9 @@ class EmpowerWxop extends WxopBase{
content: JSON.stringify(result) ,
clientIp: ""
});
console.log("receiveEmpowerMsg:---------------"+result);
if(result){
console.log("receiveEmpowerMsg:---------------"+result.ComponentVerifyTicket);
result=result.xml;
if(result.InfoType=="component_verify_ticket"){//推送component_verify_ticket协议
await this.cacheManager["WxcomponentverifyticketCache"].cacheComponentVerifyTicket(result.ComponentVerifyTicket);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment