增加续期备注

Test_IRC_Net8^2
hang 2026-06-03 17:56:07 +08:00
parent bb3f612772
commit 73fa62e6a2
1 changed files with 3 additions and 3 deletions

View File

@ -936,13 +936,13 @@ public class OSSService(IOptionsMonitor<ObjectStoreServiceOptions> options,
{
// 过期时间 ≤ 当前时间 + 15分钟 时需要续期
if (ObjectStoreServiceOptions.ObjectStoreUse == "AliyunOSS")
{
if (AliyunOSSTempToken != null && AliyunOSSTempToken.Expiration > DateTime.UtcNow.AddMinutes(15))
if (AliyunOSSTempToken != null && AliyunOSSTempToken.Expiration > DateTime.Now.AddMinutes(15))
{
return;
return; // 还有15分钟以上不需要续期
}
lock (_tokenLock)