File tree 1 file changed +9
-3
lines changed
1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change 1
1
// In ES2015 (or a polyfilled) environment, this will be Symbol.iterator
2
2
// istanbul ignore next (See: 'https://github.com/graphql/graphql-js/issues/2317')
3
3
export const SYMBOL_ITERATOR : string =
4
- typeof Symbol === 'function' ? Symbol . iterator : '@@iterator' ;
4
+ typeof Symbol === 'function' && Symbol . iterator != null
5
+ ? Symbol . iterator
6
+ : '@@iterator' ;
5
7
6
8
// In ES2017 (or a polyfilled) environment, this will be Symbol.asyncIterator
7
9
// istanbul ignore next (See: 'https://github.com/graphql/graphql-js/issues/2317')
8
10
export const SYMBOL_ASYNC_ITERATOR : string =
9
- typeof Symbol === 'function' ? Symbol . asyncIterator : '@@asyncIterator' ;
11
+ typeof Symbol === 'function' && Symbol . asyncIterator != null
12
+ ? Symbol . asyncIterator
13
+ : '@@asyncIterator' ;
10
14
11
15
// istanbul ignore next (See: 'https://github.com/graphql/graphql-js/issues/2317')
12
16
export const SYMBOL_TO_STRING_TAG : string =
13
- typeof Symbol === 'function' ? Symbol . toStringTag : '@@toStringTag' ;
17
+ typeof Symbol === 'function' && Symbol . toStringTag != null
18
+ ? Symbol . toStringTag
19
+ : '@@toStringTag' ;
You can’t perform that action at this time.
0 commit comments