pub fn as_graphql_error( message: &'static str, code: StatusCode, ) -> Box<dyn Fn(Error) -> Error>
A convenience function to create a GraphQL error from an existing error, intended to be used with .map_err()
.map_err()