From 6daedd5dbc66ad84bd008638d80648083810d41e Mon Sep 17 00:00:00 2001 From: ypsdf1 Date: Mon, 26 Oct 2026 18:41:34 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AC=AC57=E6=89=B9=E7=BB=AD9:=20=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=E5=BC=B9=E7=AA=97=E5=8D=A1=E6=AD=BB(poll=E7=BB=88?= =?UTF-8?q?=E6=80=81=E5=89=8D=E5=85=B3drawer)+token=E5=81=B6=E5=8F=91?= =?UTF-8?q?=E6=97=A0=E6=95=88(web=5Flogin=5Fverified=20fallback)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/account.php | 14 +++++++++++++- player.php | 5 +++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/api/account.php b/api/account.php index dec4718..c676b3c 100644 --- a/api/account.php +++ b/api/account.php @@ -315,7 +315,19 @@ function acctAuthPlayer() { if ($ban !== null) error('账号已被封禁:' . $ban, 403); $blk = playerWebBlacklistReason($player); if ($blk !== null) error('你已被拉黑,无法进行账号安全操作', 403); - if (!isPlayerRegistered($player)) error('玩家未注册', 403); + if (!isPlayerRegistered($player)) { + // ★第57批续9:Java端已验证的玩家(web_login_verified表)放行,避免users表同步延迟导致偶发无效 + $vdb = getDB(); + try { + $vdb->exec("CREATE TABLE IF NOT EXISTS web_login_verified (player_name TEXT PRIMARY KEY, verified_at INTEGER NOT NULL)"); + $vStmt = $vdb->prepare("SELECT 1 FROM web_login_verified WHERE player_name = :player"); + $vStmt->bindValue(':player', $player, SQLITE3_TEXT); + $vRow = $vStmt->execute()->fetchArray(); + if (!$vRow) error('玩家未注册', 403); + } catch (\Throwable $e) { + error('玩家未注册', 403); + } + } return $player; } diff --git a/player.php b/player.php index 35704a6..d87551e 100644 --- a/player.php +++ b/player.php @@ -2738,19 +2738,23 @@ if ($currentVersion !== $BUILD_VERSION) { } if (d.status === 'approved') { if (_bindWizTimer) { clearInterval(_bindWizTimer); _bindWizTimer = null; } + closeDrawer(); acctBindEmailPwdStep(); return; } if (d.status === 'completed') { if (_bindWizTimer) { clearInterval(_bindWizTimer); _bindWizTimer = null; } + closeDrawer(); acctBindEmailCodeStep(d.email); return; } + closeDrawer(); acctBindEmailFinish(d.status, d.fail_reason); } catch (e) { /* 网络抖动忽略,下一轮重试 */ } } function acctBindEmailCodeStep(email) { + closeDrawer(); const _masked = (email || '').replace(/^(.).*(@.*)$/, '$1***$2'); acctModalSet(`
✅ 游戏内已批准,邮箱 ${_masked} 已绑定。 @@ -2822,6 +2826,7 @@ if ($currentVersion !== $BUILD_VERSION) { function acctBindEmailFinish(status, reason) { if (_bindWizTimer) { clearInterval(_bindWizTimer); _bindWizTimer = null; } + closeDrawer(); if (status === 'rejected') { acctModalSet( '
' +