Exchange API Born
This commit is contained in:
1 parent
27768a6d90
commit
e77c84b1c1
5 files changed
+29
-21
No files matched your search
+8
-17
@@ -1,8 +1,4 @@
|
||||
|
||||
|
||||
|
||||
exports.newDebugLog = function newDebugLog() {
|
||||
|
||||
exports.newDebugLog = function newDebugLog() {
|
||||
|
||||
const MODULE_NAME = "Debug Log";
|
||||
const fileSystem = require('fs');
|
||||
@@ -16,38 +12,35 @@ exports.newDebugLog = function newDebugLog() {
|
||||
let firstCall = true;
|
||||
let folderPath;
|
||||
|
||||
debugLog = {
|
||||
thisObject = {
|
||||
bot: undefined,
|
||||
fileName: undefined,
|
||||
write: write
|
||||
};
|
||||
|
||||
|
||||
|
||||
return debugLog;
|
||||
|
||||
return thisObject;
|
||||
|
||||
function createFolders() {
|
||||
|
||||
try {
|
||||
|
||||
folderPath = debugLog.bot.devTeam;
|
||||
folderPath = thisObject.bot.devTeam;
|
||||
|
||||
createFolderSync(folderPath);
|
||||
|
||||
folderPath = debugLog.bot.devTeam + "/" + debugLog.bot.type;
|
||||
folderPath = thisObject.bot.devTeam + "/" + thisObject.bot.type;
|
||||
|
||||
createFolderSync(folderPath);
|
||||
|
||||
folderPath = debugLog.bot.devTeam + "/" + debugLog.bot.type + "/" + debugLog.bot.name;
|
||||
folderPath = thisObject.bot.devTeam + "/" + thisObject.bot.type + "/" + thisObject.bot.name;
|
||||
|
||||
createFolderSync(folderPath);
|
||||
|
||||
folderPath = debugLog.bot.devTeam + "/" + debugLog.bot.type + "/" + debugLog.bot.name + "/" + debugLog.bot.version;
|
||||
folderPath = thisObject.bot.devTeam + "/" + thisObject.bot.type + "/" + thisObject.bot.name + "/" + thisObject.bot.version;
|
||||
|
||||
createFolderSync(folderPath);
|
||||
|
||||
folderPath = debugLog.bot.devTeam + "/" + debugLog.bot.type + "/" + debugLog.bot.name + "/" + debugLog.bot.version + "/" + debugLog.bot.process;
|
||||
folderPath = thisObject.bot.devTeam + "/" + thisObject.bot.type + "/" + thisObject.bot.name + "/" + thisObject.bot.version + "/" + thisObject.bot.process;
|
||||
|
||||
createFolderSync(folderPath);
|
||||
|
||||
@@ -61,7 +54,6 @@ exports.newDebugLog = function newDebugLog() {
|
||||
|
||||
}
|
||||
|
||||
|
||||
function write(Message) {
|
||||
|
||||
if (firstCall === true) {
|
||||
@@ -87,7 +79,6 @@ exports.newDebugLog = function newDebugLog() {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function createFolderSync(name) {
|
||||
try {
|
||||
fileSystem.mkdirSync( './logs/' + name)
|
||||
|
||||
Reference in new issue
Block a user