summaryrefslogtreecommitdiff
path: root/src/routes/start.rs
diff options
context:
space:
mode:
authorFxQnLr <[email protected]>2024-02-15 19:29:48 +0100
committerFxQnLr <[email protected]>2024-02-15 19:29:48 +0100
commit016fa3a31f8847d3f52800941b7f8fe5ef872240 (patch)
tree59bca278b082b0801c1a4174aac856be9ccd298f /src/routes/start.rs
parent3bc7cf8ed36016ca3da9438a98f4fe8b8e6f9e61 (diff)
downloadwebol-016fa3a31f8847d3f52800941b7f8fe5ef872240.tar
webol-016fa3a31f8847d3f52800941b7f8fe5ef872240.tar.gz
webol-016fa3a31f8847d3f52800941b7f8fe5ef872240.zip
Closes #15. No usable Error message right now
Diffstat (limited to 'src/routes/start.rs')
-rw-r--r--src/routes/start.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/routes/start.rs b/src/routes/start.rs
index 66b7cb4..ec4f98f 100644
--- a/src/routes/start.rs
+++ b/src/routes/start.rs
@@ -20,7 +20,7 @@ pub async fn start(
20) -> Result<Json<Value>, Error> { 20) -> Result<Json<Value>, Error> {
21 info!("POST request"); 21 info!("POST request");
22 let secret = headers.get("authorization"); 22 let secret = headers.get("authorization");
23 let authorized = auth(&state.config, secret)?; 23 let authorized = matches!(auth(&state.config, secret)?, crate::auth::Response::Success);
24 if authorized { 24 if authorized {
25 let device = sqlx::query_as!( 25 let device = sqlx::query_as!(
26 Device, 26 Device,