mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-17 17:36:08 +08:00
core: fix contest unlock button is not working (#616)
This commit is contained in:
1 parent
a6128a7328
commit
035670e117
1 file changed
+1
-1
@@ -839,8 +839,8 @@ export async function recalcStatus(domainId: string, tid: ObjectId) {
|
||||
export async function unlockScoreboard(domainId: string, tid: ObjectId) {
|
||||
const tdoc = await document.get(domainId, document.TYPE_CONTEST, tid);
|
||||
if (!tdoc.lockAt || tdoc.unlocked) return;
|
||||
await recalcStatus(domainId, tid);
|
||||
await edit(domainId, tid, { unlocked: true });
|
||||
await recalcStatus(domainId, tid);
|
||||
}
|
||||
|
||||
export function canViewHiddenScoreboard(this: { user: User }, tdoc: Tdoc<30>) {
|
||||
|
||||
Reference in new issue
Block a user