From ed10e14b47e0a0d409fd4b0cb5e814a55866acc6 Mon Sep 17 00:00:00 2001 From: Pavel Djundik Date: Tue, 18 Dec 2018 13:08:18 +0200 Subject: [PATCH] Empty storage directory after destroying all channels --- src/server.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/server.js b/src/server.js index 118e437f..37fcc11b 100644 --- a/src/server.js +++ b/src/server.js @@ -181,6 +181,11 @@ module.exports = function() { return; } + log.info("Exiting..."); + + // Close all client and IRC connections + manager.clients.forEach((client) => client.quit()); + if (Helper.config.prefetchStorage) { log.info("Clearing prefetch storage folder, this might take a while..."); @@ -190,11 +195,6 @@ module.exports = function() { // Forcefully exit after 3 seconds suicideTimeout = setTimeout(() => process.exit(1), 3000); - log.info("Exiting..."); - - // Close all client and IRC connections - manager.clients.forEach((client) => client.quit()); - // Close http server server.close(() => { clearTimeout(suicideTimeout);