Quick backend patch
This commit is contained in:
parent
6bdee0edc4
commit
eeff3c226f
|
@ -102,8 +102,8 @@ const startingBoard = () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
const textFromBoard = ({ state }) => {
|
const textFromBoard = ({ state }) => {
|
||||||
const turn = (this.state.blackIsNext? 'B' : 'W');
|
const turn = state?.blackIsNext ? 'B' : 'W';
|
||||||
return turn + this.state.squares.map(square => {
|
return turn + state?.squares.map(square => {
|
||||||
if (!square) {
|
if (!square) {
|
||||||
return '_';
|
return '_';
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue