Some other fixes
[vchess.git] / client / src / variants / Alice.js
index d64c077..9eb0e87 100644 (file)
@@ -3,7 +3,7 @@ import { ArrayFun } from "@/utils/array";
 
 // NOTE: alternative implementation, probably cleaner = use only 1 board
 // TODO? atLeastOneMove() would be more efficient if rewritten here (less sideBoard computations)
-export const VariantRules = class AliceRules extends ChessRules {
+export class AliceRules extends ChessRules {
   static get ALICE_PIECES() {
     return {
       s: "p",
@@ -263,10 +263,7 @@ export const VariantRules = class AliceRules extends ChessRules {
   }
 
   getCurrentScore() {
-    if (this.atLeastOneMove())
-      // game not over
-      return "*";
-
+    if (this.atLeastOneMove()) return "*";
     const pieces = Object.keys(V.ALICE_CODES);
     const color = this.turn;
     const kp = this.kingPos[color];