From da066a344515fdc7f1a3a107605c8116cc8a8b36 Mon Sep 17 00:00:00 2001 From: jake Date: Wed, 27 Apr 2022 13:09:58 -0600 Subject: [PATCH] move EntityGatewayTransaction to end of file --- src/entity/gateway/entitygateway.rs | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/src/entity/gateway/entitygateway.rs b/src/entity/gateway/entitygateway.rs index 4ec2c74..aaf7972 100644 --- a/src/entity/gateway/entitygateway.rs +++ b/src/entity/gateway/entitygateway.rs @@ -16,17 +16,6 @@ pub enum GatewayError { PgError(#[from] sqlx::Error) } -#[async_trait::async_trait] -pub trait EntityGatewayTransaction: Send + Sync { - fn gateway<'a>(&'a mut self) -> &'a mut dyn EntityGateway { - unimplemented!() - } - - async fn commit(self: Box) -> Result<(), GatewayError> { - unimplemented!() - } -} - #[async_trait::async_trait] pub trait EntityGateway: Send + Sync { @@ -155,3 +144,15 @@ pub trait EntityGateway: Send + Sync { unimplemented!(); } } + + +#[async_trait::async_trait] +pub trait EntityGatewayTransaction: Send + Sync { + fn gateway<'a>(&'a mut self) -> &'a mut dyn EntityGateway { + unimplemented!() + } + + async fn commit(self: Box) -> Result<(), GatewayError> { + unimplemented!() + } +}