summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2023-10-07 15:13:54 +0200
committerTor Andersson <tor@ccxvii.net>2023-12-10 18:16:55 +0100
commit936a573b340afda735139318646cca057a6d2c03 (patch)
tree683b4aeadb9c0cd92fa1e76745c3306b1786d494
parent29064e62bfbacab6030bf07b4efe65d75e625064 (diff)
downloadplantagenet-936a573b340afda735139318646cca057a6d2c03.tar.gz
Revert "Fix update_aliases so it works with patch_replay.js"
This reverts commit d01f5507ebf75427118135debf7ff772315cb9fe.
-rw-r--r--rules.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/rules.js b/rules.js
index 0bf3a17..d59a622 100644
--- a/rules.js
+++ b/rules.js
@@ -782,8 +782,10 @@ function update_aliases() {
}
function load_state(state) {
- game = state
- update_aliases()
+ if (game !== state) {
+ game = state
+ update_aliases()
+ }
}
function push_state(next) {