File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change 1
1
import { inspect } from './inspect' ;
2
2
3
+ const isProduction = typeof process !== 'undefined' && process . env && process . env . NODE_ENV === 'production' ;
4
+
3
5
/**
4
6
* A replacement for instanceof which includes an error warning when multi-realm
5
7
* constructors are detected.
@@ -9,7 +11,7 @@ import { inspect } from './inspect';
9
11
export const instanceOf : ( value : unknown , constructor : Constructor ) => boolean =
10
12
/* c8 ignore next 6 */
11
13
// FIXME: https://github.com/graphql/graphql-js/issues/2317
12
- globalThis . process && globalThis . process . env . NODE_ENV === 'production'
14
+ isProduction
13
15
? function instanceOf ( value : unknown , constructor : Constructor ) : boolean {
14
16
return value instanceof constructor ;
15
17
}
You can’t perform that action at this time.
0 commit comments