diff --git a/js/login-gate.js b/js/login-gate.js index d222ca5..978710e 100644 --- a/js/login-gate.js +++ b/js/login-gate.js @@ -56,7 +56,9 @@ /* 和服务器对一次(在别的应用重新登录过 / 在别处退出过,本机标记会过期) */ if (O) { - fetch('/api/mp/public/auth/status?openid=' + encodeURIComponent(O)) /* 只读,查不到不建记录 */ + /* 11-07 从 taidong.douba.top 进来时那边没有 auth/status(404)→ 非 mp 域名改查 mp 绝对地址(mp 已允许跨域 *,体重会话 0c1f342e 提) */ + var ST = location.hostname === 'mp.yizhezhe.com' ? '' : 'https://mp.yizhezhe.com'; + fetch(ST + '/api/mp/public/auth/status?openid=' + encodeURIComponent(O)) /* 只读,查不到不建记录 */ .then(function (r) { return r.ok ? r.json() : null; }) .then(function (j) { if (!j || j.code !== 200 || !j.result) return;