Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: detect default client if not first in config #238

Merged
merged 4 commits into from
Nov 4, 2022

Conversation

PanMisza
Copy link
Contributor

@PanMisza PanMisza commented Oct 23, 2022

This PR resolves issue when default client is not defined as first one in clients.

❌ not working

clients: {
  cached: {
    host: GQL_HOST,
    schema: './config/introspection.json',
    preferGETQueries: false,
  },
  default: {
    host: GQL_HOST,
    schema: './config/introspection.json',
  },
},

Error: [vite-node] [VITE_ERROR] virtual:nuxt:./.nuxt/gql.mjs

✅ works

clients: {
  default: {
    host: GQL_HOST,
    schema: './config/introspection.json',
  },
  cached: {
    host: GQL_HOST,
    schema: './config/introspection.json',
    preferGETQueries: false,
  },
},

@codecov
Copy link

codecov bot commented Oct 23, 2022

Codecov Report

Merging #238 (7948ab8) into main (e66a108) will not change coverage.
The diff coverage is 100.00%.

❗ Current head 7948ab8 differs from pull request most recent head 1217823. Consider uploading reports for the commit 1217823 to get more accurate results

@@           Coverage Diff           @@
##             main     #238   +/-   ##
=======================================
  Coverage   92.92%   92.92%           
=======================================
  Files           5        5           
  Lines         537      537           
  Branches      109      107    -2     
=======================================
  Hits          499      499           
  Misses         37       37           
  Partials        1        1           
Impacted Files Coverage Δ
src/utils.ts 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@Diizzayy Diizzayy self-assigned this Oct 23, 2022
@Diizzayy Diizzayy merged commit 61a2768 into Diizzayy:main Nov 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants