Don't ever allow requestOptions to be undefined.

This commit is contained in:
Jesse Rosenberger 2018-10-04 23:07:48 +03:00
parent f1bc734377
commit 98d4fc3674
No known key found for this signature in database
GPG key ID: C0CCCF81AA6C08D8

View file

@ -58,7 +58,7 @@ const NoIntrospection = (context: ValidationContext) => ({
export class ApolloServerBase {
public subscriptionsPath?: string;
public graphqlPath: string = '/graphql';
public requestOptions: Partial<GraphQLOptions<any>>;
public requestOptions: Partial<GraphQLOptions<any>> = Object.create(null);
private context?: Context | ContextFunction;
private engineReportingAgent?: EngineReportingAgent;