diff --git a/js/chess.js b/js/chess.js index 7381e77..9f9972d 100644 --- a/js/chess.js +++ b/js/chess.js @@ -228,7 +228,7 @@ function legalMoves(board, side, type, from, canCapture){ if (there) { if (boardGet(board, there, otherSide(side)) !== ' ') { legals.push(there); - } else { + } else if (forward2) { let otherBoard = board; while (otherBoard && otherBoard.move && otherBoard.move.side[0] === side[0]) { otherBoard = otherBoard.prior;