Index: backend/scripts/dailyResets.js
===================================================================
--- backend/scripts/dailyResets.js	(revision 127dcb9a5c6f4c1e4d5c4ed6719716a768278232)
+++ backend/scripts/dailyResets.js	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -1,4 +1,4 @@
-const prisma = require("../lib/prisma");
-const schedule = require("node-schedule");
+const prisma = require('../lib/prisma');
+const schedule = require('node-schedule');
 
 async function dailyResets() {
@@ -23,10 +23,10 @@
     console.log(
       `[${scriptExecutionTime.toISOString()}] Current script execution UTC date: ${
-        scriptExecutionTime.toISOString().split("T")[0]
+        scriptExecutionTime.toISOString().split('T')[0]
       }`
     );
     console.log(
       `[${scriptExecutionTime.toISOString()}] Target date for challenge expiry (YYYY-MM-DD UTC): ${
-        targetDateForQuery.toISOString().split("T")[0]
+        targetDateForQuery.toISOString().split('T')[0]
       }`
     );
@@ -56,5 +56,5 @@
         challengeUpdateResult.count
       } challenges from ${
-        targetDateForQuery.toISOString().split("T")[0]
+        targetDateForQuery.toISOString().split('T')[0]
       } as expired.`
     );
@@ -81,14 +81,12 @@
 }
 
-const job = schedule.scheduleJob("0 7 * * *", function () {
+const job = schedule.scheduleJob('0 7 * * *', function () {
   console.log(`Running scheduled daily reset at ${new Date().toISOString()}`);
   dailyResets();
 });
 
-process.on("SIGINT", function () {
+process.on('SIGINT', function () {
   job.cancel();
-  console.log("Daily reset scheduler stopped.");
+  console.log('Daily reset scheduler stopped.');
   process.exit(0);
 });
-
-dailyResets();
Index: backend/scripts/resetPostCounters.js
===================================================================
--- backend/scripts/resetPostCounters.js	(revision 127dcb9a5c6f4c1e4d5c4ed6719716a768278232)
+++ backend/scripts/resetPostCounters.js	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -1,4 +1,4 @@
-const prisma = require("../lib/prisma");
-const schedule = require("node-schedule");
+const prisma = require('../lib/prisma');
+const schedule = require('node-schedule');
 
 async function resetPostCounters() {
@@ -29,5 +29,5 @@
 }
 
-const job = schedule.scheduleJob("0 0 * * *", function () {
+const job = schedule.scheduleJob('0 0 * * *', function () {
   console.log(
     `[${new Date().toISOString()}] Running scheduled post counter reset at midnight.`
@@ -41,5 +41,5 @@
 );
 
-process.on("SIGINT", function () {
+process.on('SIGINT', function () {
   job.cancel();
   console.log(
@@ -52,3 +52,2 @@
   `[${new Date().toISOString()}] Running initial post counter reset...`
 );
-resetPostCounters();
Index: backend/scripts/scriptForTesting.js
===================================================================
--- backend/scripts/scriptForTesting.js	(revision 127dcb9a5c6f4c1e4d5c4ed6719716a768278232)
+++ backend/scripts/scriptForTesting.js	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -1,5 +1,5 @@
-const { start } = require("repl");
-const prisma = require("../lib/prisma");
-const { sendModeratorEmail } = require("../services/emailService");
+const { start } = require('repl');
+const prisma = require('../lib/prisma');
+const { sendModeratorEmail } = require('../services/emailService');
 // async function getTodaysChallenges() {
 //   try {
@@ -87,5 +87,5 @@
 
     // 2. Check if there are any posts older than the threshold
-    const postsToReviewCount = await prisma.to_be_reviewed.count({
+    const posts = await prisma.to_be_reviewed.findMany({
       where: {
         created_at: {
@@ -93,13 +93,28 @@
         },
       },
+      select: {
+        title: true,
+        created_at: true,
+      },
+      orderBy: {
+        created_at: 'asc',
+      },
     });
 
-    console.log(`Found ${postsToReviewCount} post(s) older than 24 hours.`);
+    console.log(`Found ${posts.length} post(s) older than 24 hours.`);
 
     // 3. If no old posts, exit gracefully
-    if (postsToReviewCount === 0) {
-      console.log("No old posts to review. No emails sent.");
+    if (posts.length === 0) {
+      console.log('No old posts to review. No emails sent.');
       return;
     }
+    console.log('Posts awaiting review:');
+    posts.forEach((post, index) => {
+      console.log(
+        `${index + 1}. ${post.title} (ID: ${
+          post.id
+        }) - Created at: ${post.created_at.toISOString()}`
+      );
+    });
 
     // 4. If there are old posts, get all moderators
@@ -115,5 +130,5 @@
     if (moderators.length === 0) {
       console.log(
-        "Found old posts, but no moderators are defined in the system."
+        'Found old posts, but no moderators are defined in the system.'
       );
       return;
@@ -123,8 +138,8 @@
 
     moderatorEmails.forEach((email) => {
-      sendModeratorEmail(email, postsToReviewCount);
+      sendModeratorEmail(email, posts);
     });
   } catch (error) {
-    console.error("Error in sendEmailToModerators script:", error);
+    console.error('Error in sendEmailToModerators script:', error);
     process.exitCode = 1;
   } finally {
Index: backend/scripts/sendEmailToModerator.js
===================================================================
--- backend/scripts/sendEmailToModerator.js	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
+++ backend/scripts/sendEmailToModerator.js	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -0,0 +1,122 @@
+require('dotenv').config({
+  path: require('path').resolve(__dirname, '../.env'),
+});
+const { sendModeratorEmail } = require('../services/emailService');
+const schedule = require('node-schedule');
+const prisma = require('../lib/prisma');
+
+async function sendmailToModerators() {
+  const scriptExecutionTime = new Date();
+  console.log(
+    `[${scriptExecutionTime.toISOString()}] Starting moderator email check process`
+  );
+
+  try {
+    const oneDayAgo = new Date();
+    oneDayAgo.setDate(oneDayAgo.getDate());
+
+    const posts = await prisma.to_be_reviewed.findMany({
+      where: {
+        created_at: {
+          lt: oneDayAgo,
+        },
+      },
+      select: {
+        title: true,
+        created_at: true,
+      },
+      orderBy: {
+        created_at: 'asc',
+      },
+    });
+
+    console.log(
+      `[${scriptExecutionTime.toISOString()}] Found ${
+        posts.length
+      } post(s) older than 24 hours.`
+    );
+
+    // 3. If no old posts, exit gracefully
+    if (posts.length === 0) {
+      console.log('No old posts to review. No emails sent.');
+      return;
+    }
+
+    // 4. If there are old posts, get all moderators
+    const moderators = await prisma.users.findMany({
+      where: {
+        isModerator: true,
+      },
+      select: {
+        email: true, // Only select the email field
+      },
+    });
+
+    if (moderators.length === 0) {
+      console.log(
+        `[${scriptExecutionTime.toISOString()}] Found old posts, but no moderators are defined in the system.`
+      );
+      return;
+    }
+
+    const moderatorEmails = moderators.map((m) => m.email);
+    console.log(
+      `[${scriptExecutionTime.toISOString()}] Sending emails to ${
+        moderatorEmails.length
+      } moderators`
+    );
+
+    // Send emails to each moderator
+    for (const email of moderatorEmails) {
+      try {
+        await sendModeratorEmail(email, posts);
+        console.log(
+          `[${scriptExecutionTime.toISOString()}] Email sent to ${email}`
+        );
+      } catch (emailError) {
+        console.error(
+          `[${scriptExecutionTime.toISOString()}] Error sending email to ${email}:`,
+          emailError
+        );
+      }
+    }
+
+    console.log(
+      `[${scriptExecutionTime.toISOString()}] Moderator notification process completed`
+    );
+  } catch (error) {
+    console.error(
+      `[${scriptExecutionTime.toISOString()}] Error in sendEmailToModerators script:`,
+      error
+    );
+    process.exitCode = 1;
+  } finally {
+    await prisma.$disconnect();
+    console.log(
+      `[${scriptExecutionTime.toISOString()}] Prisma client disconnected.`
+    );
+  }
+}
+
+const job = schedule.scheduleJob('0 7 * * *', function () {
+  console.log(
+    `[${new Date().toISOString()}] Running scheduled moderator email check`
+  );
+  sendmailToModerators();
+});
+
+console.log(
+  `[${new Date().toISOString()}] Next scheduled run: ${job.nextInvocation()}`
+);
+
+process.on('SIGINT', function () {
+  job.cancel();
+  console.log(
+    `[${new Date().toISOString()}] Moderator email scheduler stopped`
+  );
+  process.exit(0);
+});
+
+console.log(
+  `[${new Date().toISOString()}] Running initial moderator email check...`
+);
Index: backend/services/emailService.js
===================================================================
--- backend/services/emailService.js	(revision 127dcb9a5c6f4c1e4d5c4ed6719716a768278232)
+++ backend/services/emailService.js	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -1,8 +1,8 @@
-const nodemailer = require("nodemailer");
+const nodemailer = require('nodemailer');
 
 const transporter = nodemailer.createTransport({
   host: process.env.EMAIL_HOST,
   port: parseInt(process.env.EMAIL_PORT, 10),
-  secure: process.env.EMAIL_PORT === "465",
+  secure: process.env.EMAIL_PORT === '465',
   auth: {
     user: process.env.EMAIL_USER,
@@ -13,7 +13,7 @@
 const sendApprovalEmail = async (userEmail, postTitle) => {
   const mailOptions = {
-    from: "FinkiRanked",
+    from: 'FinkiRanked',
     to: userEmail,
-    subject: "Your Forum Post has been Approved!",
+    subject: 'Your Forum Post has been Approved!',
     html: `
         <h1>Success!</h1>
@@ -36,7 +36,7 @@
 const sendDeletionEmail = async (userEmail, postTitle) => {
   const mailOptions = {
-    from: "FinkiRanked",
+    from: 'FinkiRanked',
     to: userEmail,
-    subject: "Your Forum Post has been discared",
+    subject: 'Your Forum Post has been discared',
     html: `
         <h1>Your Forum Post contains harmfull or innapropriate language</h1>
@@ -57,12 +57,29 @@
   }
 };
-const sendModeratorEmail = async (userEmail, postsNumber) => {
+const sendModeratorEmail = async (userEmail, posts) => {
+  const postsList = posts
+    .map((post, index) => {
+      const date = new Date(post.created_at);
+      const formattedDate = date.toLocaleDateString('en-GB', {
+        day: 'numeric',
+        month: 'long',
+        year: 'numeric',
+      });
+      return `<li style="margin-bottom: 8px;"><strong>${post.title}</strong> (Created: ${formattedDate})</li>`;
+    })
+    .join('');
   const mailOptions = {
-    from: "FinkiRanked",
+    from: 'FinkiRanked',
     to: userEmail,
-    subject: "Action Required: Posts Awaiting Review",
+    subject: 'Action Required: Posts Awaiting Review',
     html: `
         <h1>Action Required: Posts Awaiting Review</h1>
-        <p>This is an automated notification to let you know that there are <strong>${postsNumber}</strong> forum post(s) that have been waiting for review for more than 24 hours.</p>
+        <p>This is an automated notification to let you know that there are <strong>${posts.length}</strong> forum post(s) that have been waiting for review for more than 24 hours.</p>
+        
+        <h3>Posts requiring review:</h3>
+        <ul style="padding-left: 20px;">
+          ${postsList}
+        </ul>
+        
         <p>Please log in to the moderator dashboard at your earliest convenience to review and approve or reject these submissions.</p>
         <br>
Index: ecosystem.config.js
===================================================================
--- ecosystem.config.js	(revision 127dcb9a5c6f4c1e4d5c4ed6719716a768278232)
+++ ecosystem.config.js	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -1,2 +1,10 @@
+const dotenv = require('dotenv');
+const path = require('path');
+
+const backendEnv =
+  dotenv.config({
+    path: path.resolve(__dirname, 'backend', '.env'),
+  }).parsed || {};
+
 module.exports = {
   apps: [
@@ -8,4 +16,5 @@
       instances: 1,
       exec_mode: 'fork',
+      env: backendEnv,
     },
     {
@@ -16,4 +25,14 @@
       instances: 1,
       exec_mode: 'fork',
+      env: backendEnv,
+    },
+    {
+      name: 'mail-moderator',
+      script: './backend/scripts/sendEmailToModerator.js',
+      autorestart: true,
+      watch: false,
+      instances: 1,
+      exec_mode: 'fork',
+      env: backendEnv,
     },
   ],
Index: package-lock.json
===================================================================
--- package-lock.json	(revision 127dcb9a5c6f4c1e4d5c4ed6719716a768278232)
+++ package-lock.json	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -6,4 +6,5 @@
     "": {
       "dependencies": {
+        "dotenv": "^17.2.0",
         "pm2": "^6.0.8"
       }
@@ -511,4 +512,16 @@
       "engines": {
         "node": ">= 14"
+      }
+    },
+    "node_modules/dotenv": {
+      "version": "17.2.0",
+      "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-17.2.0.tgz",
+      "integrity": "sha512-Q4sgBT60gzd0BB0lSyYD3xM4YxrXA9y4uBDof1JNYGzOXrQdQ6yX+7XIAqoFOGQFOTK1D3Hts5OllpxMDZFONQ==",
+      "license": "BSD-2-Clause",
+      "engines": {
+        "node": ">=12"
+      },
+      "funding": {
+        "url": "https://dotenvx.com"
       }
     },
Index: package.json
===================================================================
--- package.json	(revision 127dcb9a5c6f4c1e4d5c4ed6719716a768278232)
+++ package.json	(revision d3070ceb2c558e6c32050c288f76753bfe63b3ec)
@@ -1,4 +1,5 @@
 {
   "dependencies": {
+    "dotenv": "^17.2.0",
     "pm2": "^6.0.8"
   }
