Bump eslint-plugin-import to avoid vulnerability in dependency
This commit is contained in:
parent
10695e6a20
commit
ed9506bbaf
1660 changed files with 67726 additions and 27926 deletions
7
node_modules/es-abstract/2016/IteratorClose.js
generated
vendored
7
node_modules/es-abstract/2016/IteratorClose.js
generated
vendored
|
|
@ -5,6 +5,7 @@ var GetIntrinsic = require('get-intrinsic');
|
|||
var $TypeError = GetIntrinsic('%TypeError%');
|
||||
|
||||
var Call = require('./Call');
|
||||
var CompletionRecord = require('./CompletionRecord');
|
||||
var GetMethod = require('./GetMethod');
|
||||
var IsCallable = require('./IsCallable');
|
||||
var Type = require('./Type');
|
||||
|
|
@ -15,10 +16,10 @@ module.exports = function IteratorClose(iterator, completion) {
|
|||
if (Type(iterator) !== 'Object') {
|
||||
throw new $TypeError('Assertion failed: Type(iterator) is not Object');
|
||||
}
|
||||
if (!IsCallable(completion)) {
|
||||
throw new $TypeError('Assertion failed: completion is not a thunk for a Completion Record');
|
||||
if (!IsCallable(completion) && !(completion instanceof CompletionRecord)) {
|
||||
throw new $TypeError('Assertion failed: completion is not a thunk representing a Completion Record, nor a Completion Record instance');
|
||||
}
|
||||
var completionThunk = completion;
|
||||
var completionThunk = completion instanceof CompletionRecord ? function () { return completion['?'](); } : completion;
|
||||
|
||||
var iteratorReturn = GetMethod(iterator, 'return');
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue