Skip to content

Commit

Permalink
Fixed GraphQL handler
Browse files Browse the repository at this point in the history
  • Loading branch information
zaychenko-sergei committed Oct 12, 2023
1 parent ce7345c commit 1035744
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/app/api-server/src/http_server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,12 @@ async fn root_handler() -> impl axum::response::IntoResponse {
/////////////////////////////////////////////////////////////////////////////////////////

async fn graphql_handler(
schema: axum::extract::Extension<kamu_adapter_graphql::Schema>,
axum::extract::Extension(schema): axum::extract::Extension<kamu_adapter_graphql::Schema>,
axum::extract::Extension(catalog): axum::extract::Extension<dill::Catalog>,
req: async_graphql_axum::GraphQLRequest,
) -> async_graphql_axum::GraphQLResponse {
schema.execute(req.into_inner()).await.into()
let graphql_request = req.into_inner().data(catalog);
schema.execute(graphql_request).await.into()
}

/////////////////////////////////////////////////////////////////////////////////////////
Expand Down

0 comments on commit 1035744

Please sign in to comment.