I'm trying to inject Nest's Logger into the graphQL module like so:
driver: ApolloDriver,
inject: [Logger],
useFactory: (logger: Logger) => ({
autoSchemaFile: join(process.cwd(), 'src/schema.gql'),
sortSchema: true,
context: ({ req, res }) => ({ req, res }),
formatError: new ApolloErrorConverter({
logger: logger,
}),
}),
}),```
Error: ERROR [ExceptionHandler] Nest can't resolve dependencies of the GqlModuleOptions (?). Please make sure that the argument Logger at index [0] is available in the GraphQLModule context.