Remove echo
This commit is contained in:
parent
20f37abbfd
commit
1012967129
3 changed files with 0 additions and 32 deletions
|
|
@ -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
|
||||
}
|
||||
|
|
|
|||
|
|
@ -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, <<key:utf8>>)),
|
||||
)
|
||||
echo "sha" <> sha_api_key
|
||||
case
|
||||
string.lowercase(
|
||||
bit_array.base16_encode(crypto.hash(crypto.Sha256, <<key:utf8>>)),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue