From 9d01912670075ba3ff2715187ff35a33bed24363 Mon Sep 17 00:00:00 2001 From: shockrah Date: Mon, 28 Dec 2020 21:57:47 -0800 Subject: [PATCH] Adding hook for getting jwt from login Also missed a lazy_static removal in db-lib --- server-api/db/src/lib.rs | 2 -- server-api/src/main.rs | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/server-api/db/src/lib.rs b/server-api/db/src/lib.rs index 37310e4..68e0f5d 100644 --- a/server-api/db/src/lib.rs +++ b/server-api/db/src/lib.rs @@ -1,5 +1,3 @@ -#[macro_use] extern crate lazy_static; - extern crate serde; pub mod member; pub mod common; diff --git a/server-api/src/main.rs b/server-api/src/main.rs index 32def6b..2dc2081 100644 --- a/server-api/src/main.rs +++ b/server-api/src/main.rs @@ -51,7 +51,7 @@ async fn route_dispatcher(pool: &Pool, resp: &mut Response, meth: &Method, const DELETE: &Method = &Method::DELETE; match (meth, path) { /* AUTHENTICATION */ - (POST, routes::AUTH_LOGIN) => auth::login_get_jwt(resp, params).await, + (POST, routes::AUTH_LOGIN) => auth::login_get_jwt(pool, resp, params).await, /* INVITES */ (GET, routes::INVITE_CREATE) => invites::create(pool, resp, params).await, (GET, routes::INVITE_JOIN) => invites::join(pool, resp, params).await,