From 6f10b38369cc92057a25cc0150727aeeeaa6f1d1 Mon Sep 17 00:00:00 2001
From: Benjamin Auder <benjamin.auder@somewhere>
Date: Sat, 25 Jul 2020 11:41:58 +0200
Subject: [PATCH] Fix bug in Allmate2

---
 client/src/variants/Allmate2.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/client/src/variants/Allmate2.js b/client/src/variants/Allmate2.js
index 9b60a5f6..259faa74 100644
--- a/client/src/variants/Allmate2.js
+++ b/client/src/variants/Allmate2.js
@@ -63,7 +63,7 @@ export class Allmate2Rules extends ChessRules {
               case V.KING:
                 // Do not allow castling to escape from check
                 oppMoves = super.getSlideNJumpMoves(
-                  [x, y],
+                  [i, j],
                   V.steps[V.ROOK].concat(V.steps[V.BISHOP]),
                   "oneStep"
                 );
-- 
2.44.0