From 4ca2e9b1886571b7e666a0ec8f84b13e715a5cb0 Mon Sep 17 00:00:00 2001 From: Matthew R Date: Sun, 29 Mar 2020 05:28:40 -0400 Subject: [PATCH] fix memory checking issue --- src/intervals/memory.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/intervals/memory.ts b/src/intervals/memory.ts index f0806f8..04fabe5 100644 --- a/src/intervals/memory.ts +++ b/src/intervals/memory.ts @@ -16,7 +16,9 @@ export const memoryLimits = { export default function memory(client: Client) { setInterval(async () => { const accounts = await client.db.Account.find(); + console.log(accounts); for (const acc of accounts) { + console.log(acc); if (acc.root) return; // memory in bytes const mem = Number(await client.util.exec(`memory ${acc.username}`)) * 1000; @@ -34,6 +36,7 @@ export default function memory(client: Client) { /* if the user has exceeded their soft memory limit, which is the one described in the resource limit guidelines, we'll inform staff. */ + console.log(memoryConversion, userLimits.soft, userLimits.hard); if (memoryConversion >= userLimits.soft) { client.signale.info(`RAM Soft Limit Reached | ${acc.username} | ${memoryConversion}/${userLimits.soft} MB`); const embed = new RichEmbed();