Skip to content

Commit

Permalink
Address ra0x3 feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
deekerno committed May 16, 2023
1 parent 8239b11 commit b33a0ac
Show file tree
Hide file tree
Showing 3 changed files with 226 additions and 190 deletions.
6 changes: 3 additions & 3 deletions packages/fuel-indexer-api-server/src/uses.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,13 @@ pub(crate) async fn query_graph(
.await
{
Ok(schema) => {
let dynamic_schema = build_dynamic_schema(schema.clone()).await?;
let dynamic_schema = build_dynamic_schema(schema.clone())?;
let user_query = req.0.query.clone();
let response =
execute_query(req.into_inner(), dynamic_schema, user_query, pool, schema)
.await?;
let json_res = axum::Json(response);
Ok(json_res)
let data = serde_json::json!({ "data": response });
Ok(axum::Json(data))
}
Err(_e) => Err(ApiError::Http(HttpError::NotFound(format!(
"The graph '{namespace}.{identifier}' was not found."
Expand Down
Loading

0 comments on commit b33a0ac

Please sign in to comment.