Skip to content

Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia

Fix GQL introspection query not sent through extension

Levin Rickert848535a34301
diff --git a/pages/graphql.vue b/pages/graphql.vue
index fc397406a..c0235b1f5 100644
--- a/pages/graphql.vue
+++ b/pages/graphql.vue
@@ -302,9 +302,9 @@
<p
v-if="
queryFields.length === 0 &&
- mutationFields.length === 0 &&
- subscriptionFields.length === 0 &&
- gqlTypes.length === 0
+ mutationFields.length === 0 &&
+ subscriptionFields.length === 0 &&
+ gqlTypes.length === 0
"
class="info"
>
@@ -505,7 +505,7 @@ export default {
try {
let headers = {}
- this.headers.forEach(header => {
+ this.headers.forEach((header) => {
headers[header.key] = header.value
})
@@ -557,7 +557,7 @@ export default {
})
let headers = {}
- this.headers.forEach(header => {
+ this.headers.forEach((header) => {
headers[header.key] = header.value
})
@@ -571,19 +571,8 @@ export default {
data: query,
}
- const reqConfig = this.$store.state.postwoman.settings.PROXY_ENABLED
- ? {
- method: "post",
- url:
- this.$store.state.postwoman.settings.PROXY_URL ||
- `https://postwoman.apollosoftware.xyz/`,
- data: reqOptions,
- }
- : reqOptions
-
- const res = await axios(reqConfig)
+ const data = await sendNetworkRequest(reqOptions, this.$store)
- const data = this.$store.state.postwoman.settings.PROXY_ENABLED ? res.data : res
const schema = gql.buildClientSchema(data.data.data)
this.schema = gql.printSchema(schema, {
commentDescriptions: true,