Commit 65b9de14 authored by daniel's avatar daniel

fix(secret): 关键字移除

parent 70f9e21c
......@@ -65,12 +65,12 @@ public class WechatMiniService {
*/
public String getMicroAccessToken(String partnerId) {
String accessToken = (String) valueOperations.get("micro_gk:access_token_" + partnerId);
log.info("===== redis access_token:" + accessToken);
// log.info("===== redis access_token:" + accessToken);
if (StringUtils.isEmpty(accessToken)) {
Partner partner = partnerService.getPartnerById(partnerId);
String aokenUrl = "https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=" + partner.getAppId() + "&secret=" + partner.getAppSecret();
String json = HttpUtil.doGet(aokenUrl, null);
log.info("URL:" + aokenUrl + ", 返回结果:" + json);
// log.info("URL:" + aokenUrl + ", 返回结果:" + json);
Map<String, Object> resultMap = JsonUtil.fromJson(json, new TypeReference<Map<String, Object>>() {
});
accessToken = resultMap.get("access_token")
......@@ -94,7 +94,7 @@ public class WechatMiniService {
Partner partner = partnerService.getPartnerById(partnerId);
String aokenUrl = "https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=" + partner.getAppId() + "&secret=" + partner.getAppSecret();
String json = HttpUtil.doGet(aokenUrl, null);
log.info("URL:" + aokenUrl + ", 重新获取小程序token返回结果:" + json);
// log.info("URL:" + aokenUrl + ", 重新获取小程序token返回结果:" + json);
Map<String, Object> resultMap = JsonUtil.fromJson(json, new TypeReference<Map<String, Object>>() {
});
accessToken = resultMap.get("access_token")
......
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