Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mergeiterator

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mergeiterator - npm Package Compare versions

Comparing version 1.4.0 to 1.4.1

dist/index.d.js

6

CHANGES.md

@@ -0,1 +1,7 @@

## 1.4.1
fix:
* proper closing sync generators returning rejected promise
## 1.4.0

@@ -2,0 +8,0 @@

14

dist/mergeiterator.js

@@ -8,2 +8,4 @@ "use strict";

var _asyncFromSync = require("./polyfills/asyncFromSync");
function _asyncIterator(iterable) { var method; if (typeof Symbol !== "undefined") { if (Symbol.asyncIterator) { method = iterable[Symbol.asyncIterator]; if (method != null) return method.call(iterable); } if (Symbol.iterator) { method = iterable[Symbol.iterator]; if (method != null) return method.call(iterable); } } throw new TypeError("Object is not async iterable"); }

@@ -53,6 +55,8 @@

if (values.length > 0) {
if (typeof values[0] === "object" && values[0] && typeof values[0].then === "function") {
yield values.shift();
const value = values.shift();
if (typeof value === "object" && value && "then" in value && typeof value.then === "function") {
yield value;
} else {
yield values.shift();
yield value;
}

@@ -94,3 +98,3 @@ } else {

try {
for (var _iterator = _asyncIterator((await sequences)), _step, _value; _step = await _iterator.next(), _iteratorNormalCompletion = _step.done, _value = await _step.value, !_iteratorNormalCompletion; _iteratorNormalCompletion = true) {
for (var _iterator = _asyncIterator((0, _asyncFromSync.forAwaitOfSyncWrapper)((await sequences))), _step, _value; _step = await _iterator.next(), _iteratorNormalCompletion = _step.done, _value = await _step.value, !_iteratorNormalCompletion; _iteratorNormalCompletion = true) {
const sequence = _value;

@@ -147,3 +151,3 @@

try {
for (var _iterator2 = _asyncIterator(sequence), _step2, _value2; _step2 = await _iterator2.next(), _iteratorNormalCompletion2 = _step2.done, _value2 = await _step2.value, !_iteratorNormalCompletion2; _iteratorNormalCompletion2 = true) {
for (var _iterator2 = _asyncIterator((0, _asyncFromSync.forAwaitOfSyncWrapper)(sequence)), _step2, _value2; _step2 = await _iterator2.next(), _iteratorNormalCompletion2 = _step2.done, _value2 = await _step2.value, !_iteratorNormalCompletion2; _iteratorNormalCompletion2 = true) {
const value = _value2;

@@ -150,0 +154,0 @@ values.push(value);

{
"name": "mergeiterator",
"version": "1.4.0",
"version": "1.4.1",
"description": "merges async iterators",

@@ -23,3 +23,3 @@ "license": "MIT",

"test": "jest",
"coverage": "npm test -- --coverage --collectCoverageFrom=src/**/*.js",
"coverage": "npm test -- --coverage --collectCoverageFrom=src/**/*.[jt]s",
"lint": "eslint . --ext .js,.ts",

@@ -29,9 +29,7 @@ "types": "tsc --noEmit",

"flowinstall": "flow-typed install --ignoreDeps=dev; flow-typed install jest",
"docs": "documentation --config documentation.yml readme src --section=API",
"postdocs": "git add README.md",
"clean": "rimraf dist",
"flowbuild": "flow-copy-source src dist",
"prebuild": "npm run docs && npm run clean && npm run flowbuild",
"build": "babel src -d dist",
"preversion": "npm run flowinstall && npm run lint && npm run types && npm test && npm run build",
"prebuild": "npm run clean && npm run flowbuild",
"build": "babel src --extensions '.ts,.js' -d dist",
"preversion": "npm run flowinstall && npm run lint && npm run flow && npm run types && npm test && npm run build",
"postpublish": "git push origin master --follow-tags",

@@ -64,4 +62,4 @@ "codecov": "codecov --token=$CODECOV_TOKEN"

"@types/jest": "^24.9.0",
"@typescript-eslint/eslint-plugin": "^2.16.0",
"@typescript-eslint/parser": "^2.16.0",
"@typescript-eslint/eslint-plugin": "^2.17.0",
"@typescript-eslint/parser": "^2.17.0",
"babel-eslint": "^10.0.3",

@@ -71,3 +69,2 @@ "babel-jest": "^24.9.0",

"codecov": "^3.6.1",
"documentation": "^12.1.4",
"eslint": "^6.8.0",

@@ -74,0 +71,0 @@ "eslint-config-airbnb-base": "^14.0.0",

@@ -52,6 +52,2 @@ # mergeiterator

<!-- Generated by documentation.js. Update this documentation by updating the source code. -->
#### Table of Contents
- [merge](#merge)

@@ -58,0 +54,0 @@ - [Parameters](#parameters)

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