diff --git a/README.md b/README.md index 76883a6..5711ba4 100644 --- a/README.md +++ b/README.md @@ -54,26 +54,3 @@ init script. If not, edit the api-test/init.sh file and set correct api-key (non sh api-test/init.sh ``` -## The rest of this readme is currently outdated and will be updated shortly - -QUIZTerm is a simple online "quiz answering" game. It provides a way for contestants to provide answers to questions, -and reveal the answers for everyone at the same time. - -Cards showing who are playing, their answer status (have they answered or not?), and when revealed, what their answer -was, will show up on everyones screen. - -Not quite finished yet, it is at a point where it is "usable" enough. - -Endpoints explained - -| Endpoint | Usage | -|--------------------------|--------------------------------------------------------------| -| /room/ | Create room with given room_id (max 200 rooms) | -| /board/ | Join a game with the given room_id | -| /board//control | Join a game with the given room_id with more control options | - - -| Ingame example | Idle player | -|--------------------------|--------------------------| -| ![Screenshot](game1.png) | ![Screenshot](game2.png) | - diff --git a/server/src/quizterm.gleam b/server/src/quizterm.gleam index 0964974..968379f 100644 --- a/server/src/quizterm.gleam +++ b/server/src/quizterm.gleam @@ -83,7 +83,6 @@ fn serve_static(filename: String) { let data = mist.send_file(path, offset: 0, limit: None) |> result.map(fn(file) { - echo "SUCCESS " <> filename response.new(200) |> response.set_header("Content-Type", case surname { Ok("css") -> "text/css" @@ -93,13 +92,11 @@ fn serve_static(filename: String) { |> response.set_body(file) }) |> result.lazy_unwrap(fn() { - echo "FAIL " <> filename response.new(404) |> response.set_body( bytes_tree.from_string("Requested resource not found") |> mist.Bytes, ) }) - echo "Attempting to serve file " <> filename <> " was " data } diff --git a/server/src/web/router.gleam b/server/src/web/router.gleam index 7112706..22b2675 100644 --- a/server/src/web/router.gleam +++ b/server/src/web/router.gleam @@ -50,12 +50,6 @@ fn handle_api( case list.key_find(req.headers, "x-api-key") { Ok(key) -> { - echo "key" <> key - echo "enc key " - <> string.lowercase( - bit_array.base16_encode(crypto.hash(crypto.Sha256, <>)), - ) - echo "sha" <> sha_api_key case string.lowercase( bit_array.base16_encode(crypto.hash(crypto.Sha256, <>)),