Skip to content

Commit

Permalink
Remove consoles
Browse files Browse the repository at this point in the history
  • Loading branch information
brophdawg11 committed Jan 18, 2023
1 parent 864ca1f commit 807964a
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions packages/react-router-dom/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1231,13 +1231,10 @@ function usePrompt({ when, message }: { when: boolean; message: string }) {

React.useEffect(() => {
if (blocker.state === "blocked") {
console.log("calling window.confirm");
let proceed = window.confirm(message);
if (proceed) {
console.log("calling setTimeout before proceed");
setTimeout(blocker.proceed, 0);
} else {
console.log("resetting");
blocker.reset();
}
}
Expand Down

0 comments on commit 807964a

Please sign in to comment.