Skip to content

Commit

Permalink
refactor: use correct keys mapping
Browse files Browse the repository at this point in the history
  • Loading branch information
Neosoulink committed Aug 13, 2024
1 parent 09ff14d commit 1e17c60
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions apps/web/src/core/pieces/pieces.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import {
ColorVariant,
PieceId,
PieceModel,
PiecesGroupModel,
PieceType
PiecesGroup,
PiecesGroupModel
} from "../../common";
import { ChessBoardComponent } from "../chess-board/chess-board.component";
import { PiecesComponent } from "./pieces.component";
Expand All @@ -25,7 +25,7 @@ export class PiecesController {

public movePiece(
color: ColorVariant,
type: `${keyof typeof PieceType}s`,
type: keyof PiecesGroup<ColorVariant>,
id: PieceId,
coords: BoardCoords
) {
Expand All @@ -41,7 +41,7 @@ export class PiecesController {

public dropPiece(
color: ColorVariant,
type: `${keyof typeof PieceType}s`,
type: keyof PiecesGroup<ColorVariant>,
id: PieceId
) {
const groups = this.component.groups;
Expand Down

0 comments on commit 1e17c60

Please sign in to comment.