fix logic chech in modules/dynamic/auto-update.js

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
kruschen 2026-01-14 18:58:37 +01:00 committed by StempunkDev
parent 21710bc426
commit cc4a7cab30

View file

@ -1068,7 +1068,8 @@ export function resolveVersionConflicts(mapVersion) {
const cellId = +polygon.getAttribute("cell"); const cellId = +polygon.getAttribute("cell");
const size = +polygon.getAttribute("size"); const size = +polygon.getAttribute("size");
if (!pointsStr || !cellId || !size) return; // points string must exist, cell attribute must be present, and size must be non-zero
if (!pointsStr || polygon.getAttribute("cell") === null || !size) return;
// Parse points string "x1,y1 x2,y2 x3,y3 ..." into array [[x1,y1], [x2,y2], ...] // Parse points string "x1,y1 x2,y2 x3,y3 ..." into array [[x1,y1], [x2,y2], ...]
const points = pointsStr const points = pointsStr