cargo fmt

This commit is contained in:
Chris Tsang 2022-11-23 23:55:24 +08:00
parent 45b391f434
commit 319f64fe64

View File

@ -12,9 +12,7 @@ pub trait LoaderTrait {
/// Source model /// Source model
type Model: ModelTrait; type Model: ModelTrait;
///
/// Used to eager load has_one relations /// Used to eager load has_one relations
///
async fn load_one<R, C>(&self, stmt: Select<R>, db: &C) -> Result<Vec<Option<R::Model>>, DbErr> async fn load_one<R, C>(&self, stmt: Select<R>, db: &C) -> Result<Vec<Option<R::Model>>, DbErr>
where where
C: ConnectionTrait, C: ConnectionTrait,
@ -22,9 +20,7 @@ pub trait LoaderTrait {
R::Model: Send + Sync, R::Model: Send + Sync,
<<Self as LoaderTrait>::Model as ModelTrait>::Entity: Related<R>; <<Self as LoaderTrait>::Model as ModelTrait>::Entity: Related<R>;
///
/// Used to eager load has_many relations /// Used to eager load has_many relations
///
async fn load_many<R, C>(&self, stmt: Select<R>, db: &C) -> Result<Vec<Vec<R::Model>>, DbErr> async fn load_many<R, C>(&self, stmt: Select<R>, db: &C) -> Result<Vec<Vec<R::Model>>, DbErr>
where where
C: ConnectionTrait, C: ConnectionTrait,