diff --git a/NewFile b/NewFile deleted file mode 100644 index e69de29b..00000000 diff --git a/client/404.html b/client/404.html index 85df60e1..69cd10f3 100644 --- a/client/404.html +++ b/client/404.html @@ -5,7 +5,7 @@ QB Reader - + @@ -65,12 +65,21 @@
-

Page Not Found

-
-

Rarely-used examples of these objects are named "Early Hints", "Variant Also Negotiates" and "Non-Authoritative Information". A 2016 proposal by Tim Bray to create a new one of these objects ends with the acknowledgement, "Thanks also to Ray Bradbury". That proposed object is named "Unavailable For Legal Reasons". An unofficial one of these objects used by Twitter's API is named for a quote from Demolition Man, "Enhance your calm". A Google easter egg produces one of these objects with the note, "The requested entity body is short and stout", in reference to a joke (*) "Coffee Pot Control Protocol" that introduced one of these things called "I'm a teapot". The 300 series of these things indicate a redirection, while the 200 series indicates success. For 10 points, identify these three-digit identifiers that include "502 Bad Gateway" and "404 Not Found".

-
-

ANSWER: HTTP status codes [accept HTTP error codes; accept HTTP codes; prompt on "HTTP responses" with "what part of the response?"; prompt on "status codes" or "error codes" with "under what protocol?"; anti-prompt on specific codes like "404 Not Found" with "can you be less specific?"]

+

Page Not Found

+
+

Rarely-used examples of these objects are named "Early Hints", "Variant Also Negotiates" and "Non-Authoritative + Information". A 2016 proposal by Tim Bray to create a new one of these objects ends with the acknowledgement, "Thanks + also to Ray Bradbury". That proposed object is named "Unavailable For Legal Reasons". An unofficial one of these + objects used by Twitter's API is named for a quote from Demolition Man, "Enhance your calm". A Google easter egg + produces one of these objects with the note, "The requested entity body is short and stout", in reference to a joke + (*) "Coffee Pot Control Protocol" that introduced one of these things called "I'm a teapot". The 300 series of these + things indicate a redirection, while the 200 series indicates success. For 10 points, identify these three-digit + identifiers that include "502 Bad Gateway" and "404 Not Found".

+
+

ANSWER: HTTP status codes [accept HTTP error codes; accept HTTP codes; prompt on + "HTTP responses" with "what part of the response?"; prompt on "status codes" or "error codes" with + "under what protocol?"; anti-prompt on specific codes like "404 Not Found" with "can you be less specific?"]

- \ No newline at end of file + diff --git a/routes/index.js b/routes/index.js index f625e524..74a17020 100644 --- a/routes/index.js +++ b/routes/index.js @@ -7,11 +7,8 @@ import userRouter from './user.js'; import webhookRouter from './api/webhook.js'; import express, { Router } from 'express'; -import { fileURLToPath } from 'url'; -import path from 'path'; const router = Router(); -const __dirname = path.dirname(fileURLToPath(import.meta.url)); router.get('/*.scss', (req, res) => { res.sendFile(req.url, { root: './scss' }); @@ -44,7 +41,7 @@ router.use(express.static('node_modules')); * 404 Error handler */ router.use((_req, res) => { - res.status(404).sendFile(path.join(__dirname, '../client', '404.html')); + res.sendFile('404.html', { root: './client' }); }); export default router;