Skip to content

Commit

Permalink
Naming
Browse files Browse the repository at this point in the history
  • Loading branch information
Jackson Kearl committed Jun 26, 2019
1 parent 4629465 commit cf5abb1
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions packages/apollo-gateway/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,10 @@ function isLocalConfig(config: GatewayConfig): config is LocalGatewayConfig {
}

function isHostedConfig(config: GatewayConfig): config is ManagedGatewayConfig {
return !(isLocalConfig(config) || isConcreteConfig(config));
return !(isLocalConfig(config) || isRemoteConfig(config));
}

function isConcreteConfig(
config: GatewayConfig,
): config is RemoteGatewayConfig {
function isRemoteConfig(config: GatewayConfig): config is RemoteGatewayConfig {
return 'serviceList' in config;
}

Expand Down Expand Up @@ -212,7 +210,7 @@ export class ApolloGateway implements GraphQLService {
): Promise<[ServiceDefinition[], boolean]> {
if (isLocalConfig(config)) return [config.localServiceList, false];

const [remoteServices, isNewService] = isConcreteConfig(config)
const [remoteServices, isNewService] = isRemoteConfig(config)
? await getServiceDefinitionsFromRemoteEndpoint({
serviceList: config.serviceList,
})
Expand Down

0 comments on commit cf5abb1

Please sign in to comment.