fix different world different admin

This commit is contained in:
2026-05-02 00:25:02 +03:00
parent 5f6855ec69
commit 2552d3d075
8 changed files with 80 additions and 51 deletions

View File

@@ -822,11 +822,12 @@
async function pollAndExecute() {
if (paused) return;
const player_id = uw.Game?.player_id;
const world_id = uw.Game?.world_id;
if (!player_id) return;
let cmdData;
try {
const res = await fetch(`${BASE_URL}/api/commands/pending?player_id=${player_id}`);
const res = await fetch(`${BASE_URL}/api/commands/pending?player_id=${player_id}&world_id=${world_id}`);
cmdData = await res.json();
} catch (e) {
log(`Poll failed: ${e}`);