diff --git a/client/src/App.js b/client/src/App.js
index d7e4875..2281f46 100644
--- a/client/src/App.js
+++ b/client/src/App.js
@@ -47,7 +47,7 @@ function App() {
function ProtectedRoute({ children }) {
const isLoggedIn = useSelector((state) => state.auth.isLoggedIn);
const token = localStorage.getItem("token");
- if (!isLoggedIn & token) {
+ if (!isLoggedIn & !token) {
Swal.fire({
title: "Unauthorized Access",
text: "You need to log in to access this page",
@@ -119,7 +119,14 @@ function App() {
}
/>
-
+
+
+
+ }
+ />