this bool never did anything other than toggle this thing
This commit is contained in:
parent
d330b38e93
commit
e30a3a5521
2 changed files with 2 additions and 11 deletions
12
Binato.js
12
Binato.js
|
@ -10,8 +10,6 @@ const app = require("express")(),
|
||||||
serverHandler = require("./server/serverHandler.js"),
|
serverHandler = require("./server/serverHandler.js"),
|
||||||
config = require("./config.json");
|
config = require("./config.json");
|
||||||
|
|
||||||
const debugMode = true;
|
|
||||||
|
|
||||||
if (config.prometheusEnabled) {
|
if (config.prometheusEnabled) {
|
||||||
// We only need to require this if prom metrics are on.
|
// We only need to require this if prom metrics are on.
|
||||||
const prom = require("prom-client");
|
const prom = require("prom-client");
|
||||||
|
@ -42,14 +40,8 @@ app.use((req, res) => {
|
||||||
req.on("end", () => {
|
req.on("end", () => {
|
||||||
switch (req.method) {
|
switch (req.method) {
|
||||||
case "GET":
|
case "GET":
|
||||||
if (req.url == "/" || req.url == "/index.html" || req.url == "/index.html") {
|
if (req.url == "/" || req.url == "/index.html" || req.url == "/index") {
|
||||||
fs.readFile("./web/serverPage.html", (err, data) => {
|
res.sendFile(`${__dirname}/web/serverPage.html`);
|
||||||
if (err) throw err;
|
|
||||||
|
|
||||||
if (debugMode) data = data.toString().replace("|isdebug?|", '<b style="color:red;">DEBUG</b>');
|
|
||||||
else data = data.toString().replace("|isdebug?|", '');
|
|
||||||
res.send(data);
|
|
||||||
});
|
|
||||||
} else if (req.url == "/chat") {
|
} else if (req.url == "/chat") {
|
||||||
fs.readFile("./web/chatPageTemplate.html", (err, data) => {
|
fs.readFile("./web/chatPageTemplate.html", (err, data) => {
|
||||||
if (err) throw err;
|
if (err) throw err;
|
||||||
|
|
|
@ -7,7 +7,6 @@
|
||||||
<pre style="border-style:double;border-width:4px;width:376px;">
|
<pre style="border-style:double;border-width:4px;width:376px;">
|
||||||
|
|
||||||
. o ..
|
. o ..
|
||||||
o . o o.o |isdebug?|
|
|
||||||
...oo
|
...oo
|
||||||
__[]__ Binato
|
__[]__ Binato
|
||||||
__|_o_o_o\__ A custom osu!Bancho
|
__|_o_o_o\__ A custom osu!Bancho
|
||||||
|
|
Loading…
Reference in a new issue