From 93efd480489a61cbba47ad660eb4e14cf4261e86 Mon Sep 17 00:00:00 2001 From: Pieter Date: Mon, 5 Feb 2024 09:39:25 +0000 Subject: [PATCH] Linting --- src/exporter.js | 17 +++++++++++------ src/helper.js | 4 ++-- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/src/exporter.js b/src/exporter.js index 7f0c0db..3407ddd 100644 --- a/src/exporter.js +++ b/src/exporter.js @@ -9,7 +9,9 @@ import beautify from "json-beautify"; const argv = minimist(process.argv.slice(2)); const discordUsername = argv.discordUsername || "Screeps Performance Server"; -const avatarURL = argv.discordAvatarUrl || "https://user-images.githubusercontent.com/48334001/189509241-7f04fe66-a5bc-4791-ada7-4f948794ceb0.png"; +const avatarURL = + argv.discordAvatarUrl || + "https://user-images.githubusercontent.com/48334001/189509241-7f04fe66-a5bc-4791-ada7-4f948794ceb0.png"; const githubOwner = argv.githubOwner || "The-International-Screeps-Bot"; const githubRepo = argv.githubRepo || "The-International-Open-Source"; export default class Exporter { @@ -184,18 +186,21 @@ export default class Exporter { const timeRun = (endTime - startTime) / 1000 / 60 / 60; // in hours const loggerText = loggerFile.success - ? `**Filtered Logs:** ${loggerFile.pasteBinUrl} (${loggerFile.lineCount - 1 - } logs)\n` + ? `**Filtered Logs:** ${loggerFile.pasteBinUrl} (${ + loggerFile.lineCount - 1 + } logs)\n` : "**Filtered Logs:** No log dump file found\n"; const historyText = historyFile.success - ? `**Milestone History:** ${historyFile.pasteBinUrl} (${historyFile.lineCount - 1 - } logs)\n` + ? `**Milestone History:** ${historyFile.pasteBinUrl} (${ + historyFile.lineCount - 1 + } logs)\n` : "**Milestone History:** No history file found\n"; return ( `**Performance Test Results**\n` + `**Commit:** ${this.commitName}\n` + - `**Fails:** ${fails.length === 0 ? "No fails!" : `${fails.length} fails` + `**Fails:** ${ + fails.length === 0 ? "No fails!" : `${fails.length} fails` }\n` + `**Game Time :** ${lastTickNumber}\n` + `**Time:** Start: ${new Date(startTime).toISOString()} - End: ${new Date( diff --git a/src/helper.js b/src/helper.js index 59c29f5..e956252 100644 --- a/src/helper.js +++ b/src/helper.js @@ -78,8 +78,8 @@ export default class Helper { await api.auth(); api.socket.connect(); - api.socket.on("connected", () => { }); - api.socket.on("auth", () => { }); + api.socket.on("connected", () => {}); + api.socket.on("auth", () => {}); api.socket.subscribe(`room:${room}`, statusUpdater); api.socket.subscribe("console", (event) => { if (event.data.messages) {