Skip to content

Commit

Permalink
适配不使用缓存时的逻辑
Browse files Browse the repository at this point in the history
  • Loading branch information
xiyuesaves committed Jun 16, 2024
1 parent 90af503 commit 2ad8fe2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main_modules/getRkey.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export async function getRkey(chatType) {
log("没有配置rkey或没有传入type");
return config.global.rkey;
}
if (!rkey || rkey.expired_time < Date.now() / 1000) {
if (!rkey || rkey.expired_time ? rkey.expired_time < Date.now() / 1000 : true) {
rkey = await fetchRkey();
if (rkey) {
log("成功更新rkey", rkey);
Expand Down

0 comments on commit 2ad8fe2

Please sign in to comment.