Index: client/src/Dashboard/components/ManagePosts.jsx
===================================================================
--- client/src/Dashboard/components/ManagePosts.jsx	(revision 47263436d41f8081a6aade7d73dc61d5562d334f)
+++ client/src/Dashboard/components/ManagePosts.jsx	(revision ccd29d833ee0ee1bfa3b13cd8ea87cd135337f97)
@@ -19,7 +19,25 @@
     post: null,
   });
+  const closeModal = () => {
+    setModal({
+      isOpen: false,
+      message: '',
+      type: '',
+      postId: null,
+      post: null,
+    });
+  };
+
+  const confirmAction = () => {
+    if (modal.type === 'delete' && modal.postId) {
+      handleDeletePost(modal.postId);
+    } else if (modal.type === 'approve' && modal.post) {
+      handleApprovePost(modal.post);
+    }
+    closeModal();
+  };
   const postsPerPage = 5;
   const user = JSON.parse(localStorage.getItem('user'));
-
+  const token = localStorage.getItem('jwt');
   useEffect(() => {
     fetchPosts();
Index: client/src/routes/ProtectedRoute.jsx
===================================================================
--- client/src/routes/ProtectedRoute.jsx	(revision 47263436d41f8081a6aade7d73dc61d5562d334f)
+++ client/src/routes/ProtectedRoute.jsx	(revision ccd29d833ee0ee1bfa3b13cd8ea87cd135337f97)
@@ -3,4 +3,5 @@
 import React, { useState, useEffect } from 'react';
 
+//Vidi dali tuka treba jwt da se implementira
 const ProtectedRoute = ({ children }) => {
   const { user, loading } = useAuth();
