New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@graphql-tools/github-loader

Package Overview
Dependencies
Maintainers
0
Versions
1232
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@graphql-tools/github-loader - npm Package Compare versions

Comparing version 8.0.14-alpha-20250209214018-c4c11834dec1f64b8b18f0beb8ceb2bf8f4b5e27 to 8.0.14-alpha-20250210020637-25e3ea9b8accaa2b06d192945a43181c9ce03922

10

cjs/index.js

@@ -7,3 +7,2 @@ "use strict";

const sync_fetch_1 = tslib_1.__importDefault(require("sync-fetch"));
const value_or_promise_1 = require("value-or-promise");
const graphql_tag_pluck_1 = require("@graphql-tools/graphql-tag-pluck");

@@ -46,4 +45,3 @@ const utils_1 = require("@graphql-tools/utils");

const { owner, name, ref, path } = extractData(pointer);
return new value_or_promise_1.ValueOrPromise(() => fetchFn('https://api.github.com/graphql', this.prepareRequest({ owner, ref, path, name, options })))
.then(response => {
return (0, utils_1.mapMaybePromise)((0, utils_1.mapMaybePromise)(fetchFn('https://api.github.com/graphql', this.prepareRequest({ owner, ref, path, name, options })), response => {
const contentType = response.headers.get('content-type');

@@ -56,8 +54,6 @@ if (contentType && contentType.includes('application/json')) {

}
})
.then(response => {
}), response => {
const status = response.status;
return this.handleResponse({ pointer, path, options, response, status });
})
.resolve();
});
}

@@ -64,0 +60,0 @@ load(pointer, options) {

import { parse } from 'graphql';
import syncFetch from 'sync-fetch';
import { ValueOrPromise } from 'value-or-promise';
import { gqlPluckFromCodeStringSync, } from '@graphql-tools/graphql-tag-pluck';
import { parseGraphQLJSON, parseGraphQLSDL, } from '@graphql-tools/utils';
import { mapMaybePromise, parseGraphQLJSON, parseGraphQLSDL, } from '@graphql-tools/utils';
import { fetch as asyncFetch } from '@whatwg-node/fetch';

@@ -41,4 +40,3 @@ // github:owner/name#ref:path/to/file

const { owner, name, ref, path } = extractData(pointer);
return new ValueOrPromise(() => fetchFn('https://api.github.com/graphql', this.prepareRequest({ owner, ref, path, name, options })))
.then(response => {
return mapMaybePromise(mapMaybePromise(fetchFn('https://api.github.com/graphql', this.prepareRequest({ owner, ref, path, name, options })), response => {
const contentType = response.headers.get('content-type');

@@ -51,8 +49,6 @@ if (contentType && contentType.includes('application/json')) {

}
})
.then(response => {
}), response => {
const status = response.status;
return this.handleResponse({ pointer, path, options, response, status });
})
.resolve();
});
}

@@ -59,0 +55,0 @@ load(pointer, options) {

{
"name": "@graphql-tools/github-loader",
"version": "8.0.14-alpha-20250209214018-c4c11834dec1f64b8b18f0beb8ceb2bf8f4b5e27",
"version": "8.0.14-alpha-20250210020637-25e3ea9b8accaa2b06d192945a43181c9ce03922",
"description": "A set of utils for faster development of GraphQL tools",

@@ -11,8 +11,7 @@ "sideEffects": false,

"@graphql-tools/executor-http": "^1.1.9",
"@graphql-tools/graphql-tag-pluck": "8.3.13-alpha-20250209214018-c4c11834dec1f64b8b18f0beb8ceb2bf8f4b5e27",
"@graphql-tools/utils": "10.8.0-alpha-20250209214018-c4c11834dec1f64b8b18f0beb8ceb2bf8f4b5e27",
"@graphql-tools/graphql-tag-pluck": "8.3.13-alpha-20250210020637-25e3ea9b8accaa2b06d192945a43181c9ce03922",
"@graphql-tools/utils": "10.8.0-alpha-20250210020637-25e3ea9b8accaa2b06d192945a43181c9ce03922",
"@whatwg-node/fetch": "^0.10.0",
"sync-fetch": "0.6.0-2",
"tslib": "^2.4.0",
"value-or-promise": "^1.0.12"
"tslib": "^2.4.0"
},

@@ -19,0 +18,0 @@ "repository": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc