diff options
author | Tor Andersson <tor@ccxvii.net> | 2023-06-03 20:56:15 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-06-03 22:43:39 +0200 |
commit | f39c75af5142db5d2fcdcf9f16d6b6cfad8f80c9 (patch) | |
tree | 439f3c0ac59ff5c5914577cf4117926f6caa34c1 | |
parent | 2f71b847f95ab249b01356b164c4e07b414c47be (diff) | |
download | andean-abyss-f39c75af5142db5d2fcdcf9f16d6b6cfad8f80c9.tar.gz |
Fix "is an object" check in may_remove_shipment.
typeof null === "object" for obscure historical reasons.
-rw-r--r-- | rules.js | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -2279,10 +2279,10 @@ states.transfer_dropped_shipments = { function may_remove_shipment() { // Captured Goods - if (typeof game.op === "object" && game.op.type === "Attack") + if (game.op !== null && typeof game.op === "object" && game.op.type === "Attack") return false // Commandeer - if (typeof game.sa === "object" && game.sa.commandeer) + if (game.sa !== null && typeof game.sa === "object" && game.sa.commandeer) return false return true } |