Skip to content

Commit

Permalink
fix routing at game
Browse files Browse the repository at this point in the history
  • Loading branch information
yusufginanjar committed Sep 28, 2022
1 parent a7b11e1 commit 930d4d0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pages/game/rps.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import React, { useState, useEffect } from "react";
import { getDatabase, ref, onValue, update } from "firebase/database";
import { getAuth, onAuthStateChanged } from "../../firebase/clientApp";
import { useSelector, useDispatch } from 'react-redux'
import { useRouter } from 'next/router';
import { nextRound, nextSet, resetRound, resetSet, win, lose, addHistory } from '../../store/gameSlice';

import styles from "../../styles/Game.module.css";
Expand All @@ -17,7 +18,7 @@ export default function Game() {
const [player, setPlayer] = useState('Player 1');
const [playerPick, setPlayerPick] = useState('');
const [comPick, setComPick] = useState('');

const router = useRouter();
const auth = getAuth();

const game = useSelector(state => {
Expand Down

0 comments on commit 930d4d0

Please sign in to comment.