mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 17:46:28 +08:00
core: 修复总是显示用户当前离线的问题
This commit is contained in:
1 parent
f9aef434cb
commit
de908236e3
2 files changed
+3
-3
No files matched your search
@@ -80,7 +80,7 @@ export function getSessionListByUid(uid: number) {
|
||||
}
|
||||
|
||||
export async function getMostRecentSessionByUid(uid: number) {
|
||||
const res = await coll.find({ uid, tokenType: TYPE_SESSION }).sort('updateAt', -1);
|
||||
const res = await coll.find({ uid, tokenType: TYPE_SESSION }).sort('updateAt', -1).toArray();
|
||||
return res[0];
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user