Skip to content

Commit

Permalink
Update poem and poem-openapi
Browse files Browse the repository at this point in the history
  • Loading branch information
Defelo committed Apr 1, 2024
1 parent 3fbcd5e commit e6a50d3
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 6 deletions.
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ serde = ["dep:serde"]
[dependencies]
itertools = { version = "0.12.0", default-features = false, features = ["use_std"] }
paste = { version = "1.0.12", default-features = false }
poem = { version = "2.0.0", default-features = false }
poem-openapi = { version = "4.0.0", default-features = false }
poem = { version = "3.0.0", default-features = false }
poem-openapi = { version = "5.0.0", default-features = false }
sea-orm = { version = "0.12.1", default-features = false, optional = true, features = ["macros"] }
serde = { version = "1.0.167", default-features = false, optional = true }
tokio-shield = { version = "0.1.0", default-features = false, optional = true }
Expand Down
1 change: 0 additions & 1 deletion src/auth.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@
#[macro_export]
macro_rules! custom_auth {
($auth:path, $checker:expr) => {
#[::poem::async_trait]
impl<'a> ::poem_openapi::ApiExtractor<'a> for $auth {
const TYPES: &'static [::poem_openapi::ApiExtractorType] =
&[::poem_openapi::ApiExtractorType::SecurityScheme];
Expand Down
3 changes: 1 addition & 2 deletions src/db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@

use std::{fmt::Debug, sync::Arc};

use poem::{async_trait, Endpoint, IntoResponse, Middleware, Response};
use poem::{Endpoint, IntoResponse, Middleware, Response};
use sea_orm::{DatabaseConnection, DatabaseTransaction, TransactionTrait};

use crate::responses::internal_server_error;
Expand Down Expand Up @@ -122,7 +122,6 @@ impl<E: Debug> Debug for DbTransactionMwEndpoint<E> {
}
}

#[async_trait]
impl<E: Endpoint> Endpoint for DbTransactionMwEndpoint<E> {
type Output = Response;

Expand Down
1 change: 0 additions & 1 deletion src/shield_mw.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ impl<E: Endpoint + 'static> Middleware<E> for ShieldMiddleware {
#[derive(Debug)]
pub struct ShieldEndpoint<E>(Arc<E>);

#[poem::async_trait]
impl<E: Endpoint + 'static> Endpoint for ShieldEndpoint<E> {
type Output = E::Output;

Expand Down

0 comments on commit e6a50d3

Please sign in to comment.