diff --git a/index.js b/index.js index 02450a1..94a856a 100644 --- a/index.js +++ b/index.js @@ -205,10 +205,10 @@ async function pageUpdate() { if (!fs.existsSync(fp)) { return 'imgs/notFound.png' - } else if (fs.readFileSync(fp).length < 1) { + } else if (fs.statSync(fp).size < 1000) { fs.rmSync(fp) } - + return '/cached/' + fn } @@ -275,8 +275,8 @@ async function pageUpdate() {

Playing ${activity.name} -
${activity.details || activity.assets.large_text || " "} -
${activity.state || activity.assets.small_text || " "} +
${(activity.details || activity.assets.large_text || " ")} +
${(activity.state || activity.assets.small_text || " ")}
${gameTimeFormatter((Date.now() - time) / 1000)}

@@ -296,8 +296,8 @@ async function pageUpdate() {

${activity.name} -
${activity.details || activity.assets.large_text || " "} -
${activity.state || activity.assets.small_text || " "} +
${(activity.details || activity.assets.large_text || " ")} +
${(activity.state || activity.assets.small_text || " ")}
${gameTimeFormatter((Date.now() - time) / 1000)}

@@ -320,13 +320,6 @@ async function pageUpdate() { html = html.replace("{SOCIALS}", addedHTML) - addedHTML = "" - - // var faqHTML = fs.readFileSync(path.join(__dirname, 'static/faq/index.html')).toString() - // addedHTML += faqHTML.substring(faqHTML.indexOf("

"), faqHTML.indexOf("")) - - html = html.replace("{FAQ}", ``) - var now = new Date() currentMonth = now.getMonth() + 1 @@ -337,10 +330,6 @@ async function pageUpdate() { html = html.replace("{SEASONAL_EFFECT}", "") } - html = '\n' + html - - html = html.replace("{THUMBOR}", getThumbor()) - var quote = randomQuotes[Math.floor(Math.random() * randomQuotes.length)] var splitQuote = quote.split(' ') diff --git a/static/style.css b/static/style.css index 9f85c59..6bc81ca 100644 --- a/static/style.css +++ b/static/style.css @@ -98,6 +98,7 @@ a { .activity>p { width: 100%; + overflow-wrap: break-word; } .activity>img {