perf:请求时将通过getCurrentUserName()方法返回的对象检验用户是否非法

This commit is contained in:
曾文豪
2024-08-07 14:09:28 +08:00
parent bb38428708
commit 1ee4b4af30
27 changed files with 295 additions and 314 deletions

View File

@@ -104,7 +104,7 @@ public class PlatformDingConfig {
* @return accessToken
* @see <a href="https://open.dingtalk.com/document/orgapp-server/obtain-orgapp-token" />
*/
public String getAccessToken(String service) {
public synchronized String getAccessToken(String service) {
DingConfigBean dingConfigBean = getConfigBean(service);
String accessToken = TsCacheService.of().get(CACHE_ACCESS_TOKEN + dingConfigBean.getAppKey(), -1);
if (!StrUtil.isEmpty(accessToken)) {