Skip to content

Commit

Permalink
re-add check for presence of flags.queries
Browse files Browse the repository at this point in the history
  • Loading branch information
klujanrosas committed Jul 26, 2018
1 parent 9e93b78 commit 93d1eb6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/apollo-cli/src/load-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export function loadConfigStep(
};
}

if (!ctx.config.queries || ctx.config.queries.length == 0) {
if (!ctx.config.queries || ctx.config.queries.length == 0 && flags.queries) {
ctx.config.queries = [
{
schema: "default",
Expand All @@ -68,7 +68,7 @@ export function loadConfigStep(
}
];
}
else if (flags.queries != '**/*.graphql') {
else if (flags.queries && flags.queries != '**/*.graphql') {
ctx.config.queries = ctx.config.queries.map((query: any) => {
return Object.assign({}, query, {
includes: flags.queries.split("\n")
Expand Down

0 comments on commit 93d1eb6

Please sign in to comment.