summaryrefslogtreecommitdiff
path: root/opendc-web/opendc-web-ui/src/util/tile-calculations.js
diff options
context:
space:
mode:
Diffstat (limited to 'opendc-web/opendc-web-ui/src/util/tile-calculations.js')
-rw-r--r--opendc-web/opendc-web-ui/src/util/tile-calculations.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/opendc-web/opendc-web-ui/src/util/tile-calculations.js b/opendc-web/opendc-web-ui/src/util/tile-calculations.js
index 764ae6ac..374ca48c 100644
--- a/opendc-web/opendc-web-ui/src/util/tile-calculations.js
+++ b/opendc-web/opendc-web-ui/src/util/tile-calculations.js
@@ -18,8 +18,8 @@ function getWallSegments(tiles) {
}
let doInsert = true
- for (let tileIndex in tiles) {
- if (tiles[tileIndex].positionX === x + dX && tiles[tileIndex].positionY === y + dY) {
+ for (const tile of tiles) {
+ if (tile.positionX === x + dX && tile.positionY === y + dY) {
doInsert = false
break
}