1
0
Fork 0
mirror of https://gitlab.com/famedly/conduit.git synced 2024-12-28 20:34:23 +01:00

cargo fix

This commit is contained in:
Timo Kösters 2022-10-08 13:04:55 +02:00 committed by Nyaaori
parent 7822a385bb
commit 50b0eb9929
No known key found for this signature in database
GPG key ID: E7819C3ED4D1F82E
22 changed files with 23 additions and 26 deletions

View file

@ -4,7 +4,6 @@ use crate::{
services, utils, Error, PduEvent, Result, Ruma, services, utils, Error, PduEvent, Result, Ruma,
}; };
use axum::{response::IntoResponse, Json}; use axum::{response::IntoResponse, Json};
use futures_util::StreamExt;
use get_profile_information::v1::ProfileField; use get_profile_information::v1::ProfileField;
use http::header::{HeaderValue, AUTHORIZATION}; use http::header::{HeaderValue, AUTHORIZATION};

View file

@ -2,13 +2,12 @@ pub mod abstraction;
pub mod key_value; pub mod key_value;
use crate::{ use crate::{
service::rooms::state_compressor::CompressedStateEvent, services, utils, Config, Error, services, utils, Config, Error,
PduEvent, Result, Services, SERVICES, PduEvent, Result, Services, SERVICES,
}; };
use abstraction::KeyValueDatabaseEngine; use abstraction::KeyValueDatabaseEngine;
use abstraction::KvTree; use abstraction::KvTree;
use directories::ProjectDirs; use directories::ProjectDirs;
use futures_util::StreamExt;
use lru_cache::LruCache; use lru_cache::LruCache;
use ruma::{ use ruma::{
events::{ events::{
@ -27,7 +26,7 @@ use std::{
path::Path, path::Path,
sync::{Arc, Mutex, RwLock}, sync::{Arc, Mutex, RwLock},
}; };
use tokio::sync::mpsc;
use tracing::{debug, error, info, warn}; use tracing::{debug, error, info, warn};
pub struct KeyValueDatabase { pub struct KeyValueDatabase {

View file

@ -7,7 +7,7 @@
#![allow(clippy::suspicious_else_formatting)] #![allow(clippy::suspicious_else_formatting)]
#![deny(clippy::dbg_macro)] #![deny(clippy::dbg_macro)]
use std::{future::Future, io, net::SocketAddr, sync::Arc, time::Duration}; use std::{future::Future, io, net::SocketAddr, time::Duration};
use axum::{ use axum::{
extract::{FromRequest, MatchedPath}, extract::{FromRequest, MatchedPath},
@ -28,7 +28,7 @@ use http::{
}; };
use opentelemetry::trace::{FutureExt, Tracer}; use opentelemetry::trace::{FutureExt, Tracer};
use ruma::api::{client::error::ErrorKind, IncomingRequest}; use ruma::api::{client::error::ErrorKind, IncomingRequest};
use tokio::{signal, sync::RwLock}; use tokio::{signal};
use tower::ServiceBuilder; use tower::ServiceBuilder;
use tower_http::{ use tower_http::{
cors::{self, CorsLayer}, cors::{self, CorsLayer},

View file

@ -8,7 +8,7 @@ use ruma::{
RoomId, UserId, RoomId, UserId,
}; };
use std::{collections::HashMap, sync::Arc}; use std::{collections::HashMap};
use crate::Result; use crate::Result;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;

View file

@ -7,7 +7,7 @@ use ruma::{
serde::Raw, serde::Raw,
RoomId, UserId, RoomId, UserId,
}; };
use std::{collections::BTreeMap, sync::Arc}; use std::{collections::BTreeMap};
pub struct Service { pub struct Service {
pub db: &'static dyn Data, pub db: &'static dyn Data,

View file

@ -3,7 +3,7 @@ pub use data::Data;
use crate::{services, Result}; use crate::{services, Result};
use image::{imageops::FilterType, GenericImageView}; use image::{imageops::FilterType, GenericImageView};
use std::sync::Arc;
use tokio::{ use tokio::{
fs::File, fs::File,
io::{AsyncReadExt, AsyncWriteExt}, io::{AsyncReadExt, AsyncWriteExt},

View file

@ -21,7 +21,7 @@ use ruma::{
serde::Raw, serde::Raw,
uint, RoomId, UInt, UserId, uint, RoomId, UInt, UserId,
}; };
use std::sync::Arc;
use std::{fmt::Debug, mem}; use std::{fmt::Debug, mem};
use tracing::{error, info, warn}; use tracing::{error, info, warn};

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;
use ruma::RoomId; use ruma::RoomId;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::{collections::HashMap, sync::Arc}; use std::{collections::HashMap};
pub use data::Data; pub use data::Data;
use ruma::{events::presence::PresenceEvent, RoomId, UserId}; use ruma::{events::presence::PresenceEvent, RoomId, UserId};

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;
use ruma::{events::SyncEphemeralRoomEvent, RoomId, UserId}; use ruma::{events::SyncEphemeralRoomEvent, RoomId, UserId};

View file

@ -1,7 +1,7 @@
mod data; mod data;
use std::{ use std::{
collections::{HashMap, HashSet}, collections::{HashMap, HashSet},
sync::{Arc, Mutex}, sync::{Mutex},
}; };
pub use data::Data; pub use data::Data;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;
use ruma::RoomId; use ruma::RoomId;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;
use ruma::{signatures::CanonicalJsonObject, EventId}; use ruma::{signatures::CanonicalJsonObject, EventId};

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;
use ruma::{RoomId, UserId}; use ruma::{RoomId, UserId};

View file

@ -5,7 +5,6 @@ pub use data::Data;
use std::{ use std::{
collections::{BTreeMap, HashMap, HashSet}, collections::{BTreeMap, HashMap, HashSet},
fmt::Debug, fmt::Debug,
iter,
sync::Arc, sync::Arc,
time::{Duration, Instant}, time::{Duration, Instant},
}; };
@ -13,7 +12,7 @@ use std::{
use crate::{ use crate::{
api::{appservice_server, server_server}, api::{appservice_server, server_server},
services, services,
utils::{self, calculate_hash}, utils::{calculate_hash},
Config, Error, PduEvent, Result, Config, Error, PduEvent, Result,
}; };
use federation::transactions::send_transaction_message; use federation::transactions::send_transaction_message;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::sync::Arc;
pub use data::Data; pub use data::Data;

View file

@ -1,5 +1,5 @@
mod data; mod data;
use std::{collections::BTreeMap, mem, sync::Arc}; use std::{collections::BTreeMap, mem};
pub use data::Data; pub use data::Data;
use ruma::{ use ruma::{