diff options
author | Bryan Newbold <bnewbold@robocracy.org> | 2018-05-15 15:16:42 -0700 |
---|---|---|
committer | Bryan Newbold <bnewbold@robocracy.org> | 2018-05-15 15:19:39 -0700 |
commit | 2233970493bec6228046a75941a2e6a04500f924 (patch) | |
tree | d80a0508032e08d9074ab1d56acee16d9de8b5c1 /rust/src/api_server.rs | |
parent | 525f21c871f4947196dc8348019d941e84bf6e3c (diff) | |
download | fatcat-2233970493bec6228046a75941a2e6a04500f924.tar.gz fatcat-2233970493bec6228046a75941a2e6a04500f924.zip |
more cleanups
Diffstat (limited to 'rust/src/api_server.rs')
-rw-r--r-- | rust/src/api_server.rs | 26 |
1 files changed, 8 insertions, 18 deletions
diff --git a/rust/src/api_server.rs b/rust/src/api_server.rs index 2dd1bd8c..d9273186 100644 --- a/rust/src/api_server.rs +++ b/rust/src/api_server.rs @@ -1,24 +1,15 @@ -//! Server implementation of fatcat. +//! API endpoint handlers -#![allow(unused_imports)] - -use chrono; -use futures::{self, Future}; - -use std::collections::HashMap; - -use self::models::*; use ConnectionPool; -use diesel; +use database_schema::container_rev::table as container_rev; use diesel::prelude::*; -use diesel::r2d2::ConnectionManager; -use r2d2; - -use swagger; - -use database_schema::creator_rev::table as container_rev; - +use futures::{self, Future}; +//use database_schema::creator_rev::table as creator_rev; +//use database_schema::file_rev::table as file_rev; +//use database_schema::release_rev::table as release_rev; +//use database_schema::work_rev::table as work_rev; use fatcat_api::models; +use fatcat_api::models::*; use fatcat_api::{Api, ApiError, ContainerIdGetResponse, ContainerLookupGetResponse, ContainerPostResponse, Context, CreatorIdGetResponse, CreatorLookupGetResponse, CreatorPostResponse, EditgroupIdAcceptPostResponse, EditgroupIdGetResponse, @@ -27,7 +18,6 @@ use fatcat_api::{Api, ApiError, ContainerIdGetResponse, ContainerLookupGetRespon FilePostResponse, ReleaseIdGetResponse, ReleaseLookupGetResponse, ReleasePostResponse, WorkIdGetResponse, WorkPostResponse}; -//#[derive(Copy, Clone)] #[derive(Clone)] pub struct Server { pub db_pool: ConnectionPool, |