Skip to content

Commit

Permalink
don't pass null as variables!
Browse files Browse the repository at this point in the history
  • Loading branch information
fredex42 committed Dec 22, 2023
1 parent d14bfe2 commit fd2321b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/scala/GraphQLServer.scala
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class GraphQLServer(documentRepo:DocumentRepo) {
IO.fromFuture(
IO {
val context = GQLQueryContext(documentRepo, tier)
Executor.execute(inUseSchema, doc, middleware = permissions :: metrics :: Nil, userContext = context, variables = variables.getOrElse(Json.Null))
Executor.execute(inUseSchema, doc, middleware = permissions :: metrics :: Nil, userContext = context, variables = variables.getOrElse(Json.obj()))
.map(_.asJson.noSpaces)
}
)
Expand Down

0 comments on commit fd2321b

Please sign in to comment.