Skip to content
This repository was archived by the owner on Jul 11, 2024. It is now read-only.

Commit 0faac22

Browse files
authored
Merge pull request #324 from Uconnect-Technologies/dev-ilyas/graphql-error-fix
fixes #323
2 parents acb267e + 19cb525 commit 0faac22

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/next/devServers/dev-ilyas.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { useGraphql } from "../graphql"
12
import wertik from "../index"
23

34
const devIlyas = async () => {

src/next/graphql/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ export const useGraphql = (props?: useGraphqlProps) => {
1010
store,
1111
configuration,
1212
}: GraphqlInitializeProps) => {
13+
props = props ? props : {}
1314
store.graphql.typeDefs = store.graphql.typeDefs.concat(
1415
get(configuration, "graphql.typeDefs", "")
1516
)
@@ -51,7 +52,7 @@ export const useGraphql = (props?: useGraphqlProps) => {
5152
console.log(
5253
`GraphQL server starting at http://localhost:${
5354
configuration.port ?? 1200
54-
}/${props.applyMiddlewareOptions.path ?? "graphql"}`
55+
}/${props?.applyMiddlewareOptions?.path ?? "graphql"}`
5556
)
5657

5758
return GraphqlApolloServer

0 commit comments

Comments
 (0)