diff options
Diffstat (limited to 'src/services/graphql/api.ts')
| -rw-r--r-- | src/services/graphql/api.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/services/graphql/api.ts b/src/services/graphql/api.ts index 33cc89a..a5be026 100644 --- a/src/services/graphql/api.ts +++ b/src/services/graphql/api.ts @@ -1,8 +1,9 @@ import { RequestType, VariablesType } from '@ts/types/app'; +import { settings } from '@utils/config'; import { GraphQLClient } from 'graphql-request'; export const getGraphQLClient = (): GraphQLClient => { - const apiUrl: string = process.env.NEXT_PUBLIC_GRAPHQL_API || ''; + const apiUrl = settings.api.url; if (!apiUrl) throw new Error('API URL not defined.'); |
