Function validate_session

Source
pub async fn validate_session(ctx: AppCtx) -> Result<(), AppError>
Expand description

Returns an error if the user_id in the session does not exist in the DB, returns None otherwise

Used by the client to gracefully handle stale sessions