aboutsummaryrefslogtreecommitdiff
path: root/planetwars-server/src/routes/users.rs
diff options
context:
space:
mode:
authorIlion Beyst <ilion.beyst@gmail.com>2021-12-30 23:40:37 +0100
committerIlion Beyst <ilion.beyst@gmail.com>2021-12-30 23:40:37 +0100
commitf5e8b4093a1527967423a3af70f2b95d4b05008f (patch)
treefd000cd7689e54b9efc73f2913ec4d1817c098b0 /planetwars-server/src/routes/users.rs
parentc6ca7cf2d1238c05f75a53934ea2f6c91efc3646 (diff)
downloadplanetwars.dev-f5e8b4093a1527967423a3af70f2b95d4b05008f.tar.xz
planetwars.dev-f5e8b4093a1527967423a3af70f2b95d4b05008f.zip
prototype bots pages
Diffstat (limited to 'planetwars-server/src/routes/users.rs')
-rw-r--r--planetwars-server/src/routes/users.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/planetwars-server/src/routes/users.rs b/planetwars-server/src/routes/users.rs
index fc77d7b..bc30b28 100644
--- a/planetwars-server/src/routes/users.rs
+++ b/planetwars-server/src/routes/users.rs
@@ -19,6 +19,7 @@ where
async fn from_request(req: &mut RequestParts<B>) -> Result<Self, Self::Rejection> {
let conn = DatabaseConnection::from_request(req).await?;
+
let TypedHeader(Authorization(bearer)) = AuthorizationHeader::from_request(req)
.await
.map_err(|_| (StatusCode::UNAUTHORIZED, "".to_string()))?;