blob: 2380760a33cb8fd103da06f6dd77a453feee4daa (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
use crate::graphql::query::*;
use async_graphql::{EmptyMutation, EmptySubscription, Schema};
use async_graphql_axum::{GraphQLRequest, GraphQLResponse};
use std::sync::Arc;
pub async fn graphql_handler(
schema: Arc<Schema<Query, EmptyMutation, EmptySubscription>>,
req: GraphQLRequest,
) -> GraphQLResponse {
schema.execute(req.into_inner()).await.into()
}
|