@graphql-tools/utils
Advanced tools
Comparing version 10.4.0-alpha-20240806151613-ec8ecec67a150b8b6e117cb473fb248e6cb92f47 to 10.4.0-alpha-20240808024617-ce2a11c8e367fb077059f28163c7d22edbcefde2
@@ -6,3 +6,3 @@ "use strict"; | ||
function debugTimerStart(name) { | ||
const debugEnvVar = globalThis?.process.env['DEBUG'] || globalThis.DEBUG; | ||
const debugEnvVar = globalThis.process?.env?.['DEBUG'] || globalThis.DEBUG; | ||
if (debugEnvVar === '1' || debugEnvVar?.includes(name)) { | ||
@@ -9,0 +9,0 @@ debugNamesOngoing.add(name); |
@@ -10,2 +10,5 @@ "use strict"; | ||
function mapAsyncIterator(iterator, onNext, onError, onEnd) { | ||
if (Symbol.asyncIterator in iterator) { | ||
iterator = iterator[Symbol.asyncIterator](); | ||
} | ||
let $return; | ||
@@ -12,0 +15,0 @@ let abruptClose; |
const debugNamesOngoing = new Set(); | ||
export function debugTimerStart(name) { | ||
const debugEnvVar = globalThis?.process.env['DEBUG'] || globalThis.DEBUG; | ||
const debugEnvVar = globalThis.process?.env?.['DEBUG'] || globalThis.DEBUG; | ||
if (debugEnvVar === '1' || debugEnvVar?.includes(name)) { | ||
@@ -5,0 +5,0 @@ debugNamesOngoing.add(name); |
@@ -7,2 +7,5 @@ import { isPromise } from './jsutils.js'; | ||
export function mapAsyncIterator(iterator, onNext, onError, onEnd) { | ||
if (Symbol.asyncIterator in iterator) { | ||
iterator = iterator[Symbol.asyncIterator](); | ||
} | ||
let $return; | ||
@@ -9,0 +12,0 @@ let abruptClose; |
{ | ||
"name": "@graphql-tools/utils", | ||
"version": "10.4.0-alpha-20240806151613-ec8ecec67a150b8b6e117cb473fb248e6cb92f47", | ||
"version": "10.4.0-alpha-20240808024617-ce2a11c8e367fb077059f28163c7d22edbcefde2", | ||
"description": "Common package containing utils and types for GraphQL tools", | ||
@@ -5,0 +5,0 @@ "sideEffects": false, |
@@ -6,2 +6,2 @@ import type { MaybePromise } from './executor.js'; | ||
*/ | ||
export declare function mapAsyncIterator<T, U>(iterator: AsyncIterator<T>, onNext: (value: T) => MaybePromise<U>, onError?: any, onEnd?: () => MaybePromise<void>): AsyncIterableIterator<U>; | ||
export declare function mapAsyncIterator<T, U>(iterator: AsyncIterable<T> | AsyncIterator<T>, onNext: (value: T) => MaybePromise<U>, onError?: any, onEnd?: () => MaybePromise<void>): AsyncIterableIterator<U>; |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
511144
11092