Skip to content

Commit

Permalink
[lib] fix: makeEmptyBoard width, height passing
Browse files Browse the repository at this point in the history
  • Loading branch information
lautarodragan committed Aug 11, 2020
1 parent fdbe9e0 commit 7fabd32
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/src/board.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Coord } from './coord'

export type Board = number[][]

export const makeEmptyBoard = (width: number, height: number): Board => Array(width).fill(null).map(y => Array(height).fill(0))
export const makeEmptyBoard = (width: number, height: number): Board => Array(height).fill(null).map(y => Array(width).fill(0))

export const mapBoard = (board: Board, callback: (x: number, y: number, value: number) => number) =>
board.map(
Expand Down

0 comments on commit 7fabd32

Please sign in to comment.