From 5d9c1d5a64e6f0fc83be3805fe270ebc3c796a74 Mon Sep 17 00:00:00 2001 From: Gregor Reitzenstein Date: Tue, 17 Nov 2020 14:38:11 +0100 Subject: [PATCH] Cleanup --- src/api.rs | 7 ++----- src/connection.rs | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/api.rs b/src/api.rs index 8d383f0..3787de5 100644 --- a/src/api.rs +++ b/src/api.rs @@ -1,6 +1,6 @@ use std::sync::Arc; -use capnp::capability::{Params, Results, Promise, FromServer}; +use capnp::capability::{Params, Results, Promise}; use crate::schema::connection_capnp; use crate::connection::Session; @@ -39,11 +39,8 @@ impl connection_capnp::bootstrap::Server for Bootstrap { fn permissions(&mut self, _: Params, - mut res: Results + _: Results ) -> Promise<(), capnp::Error> { - if self.session.user.is_some() { - } - Promise::ok(()) } diff --git a/src/connection.rs b/src/connection.rs index b72d642..3f2365e 100644 --- a/src/connection.rs +++ b/src/connection.rs @@ -54,7 +54,7 @@ async fn handshake(log: &Logger, stream: &mut TcpStream) -> Result<()> { } } -pub async fn handle_connection(log: Logger, mut stream: TcpStream) -> Result<()> { +pub async fn handle_connection(log: Logger, stream: TcpStream) -> Result<()> { //handshake(&log, &mut stream).await?; let session = Arc::new(Session::new(log));