Remove RwLock for database

This commit is contained in:
Roman Moisieiev 2025-09-11 12:54:54 +01:00
parent d8f785b0db
commit 062f826d28
15 changed files with 39 additions and 64 deletions

View file

@ -12,11 +12,10 @@ use sqlx::{
Error, FromRow, Pool, Row, Sqlite,
};
use std::{str::FromStr, sync::Arc};
use tokio::sync::RwLock;
pub struct DataBase;
impl TypeMapKey for DataBase {
type Value = Arc<RwLock<Pool<Sqlite>>>;
type Value = Arc<Pool<Sqlite>>;
}
#[derive(Debug, Clone, Deserialize, Serialize)]