From f7d581832b249e0413446e73c8acb15267895443 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Fri, 6 Oct 2023 15:53:50 +0200 Subject: fix block nesting error in can_action_sail --- rules.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/rules.js b/rules.js index 6ab5480..46b4441 100644 --- a/rules.js +++ b/rules.js @@ -4425,11 +4425,12 @@ function can_action_sail() { return false // and a valid destination - for (let to of data.seaports) + for (let to of data.seaports) { if (to !== here && !has_enemy_lord(to)) return true - if (has_enemy_lord(to) && lord_has_capability(game.command, AOW_LANCASTER_HIGH_ADMIRAL)) - return true + if (has_enemy_lord(to) && lord_has_capability(game.command, AOW_LANCASTER_HIGH_ADMIRAL)) + return true + } return false } -- cgit v1.2.3