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

@naturalcycles/js-lib

Package Overview
Dependencies
Maintainers
2
Versions
525
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@naturalcycles/js-lib - npm Package Compare versions

Comparing version 14.219.0 to 14.219.1

6

dist-esm/promise/pMap.js

@@ -41,3 +41,3 @@ import { END, ErrorMode, SKIP } from '..';

return []; // short circuit
const { concurrency = 16, errorMode = ErrorMode.THROW_IMMEDIATELY, logger = console } = opt;
const { concurrency = Infinity, errorMode = ErrorMode.THROW_IMMEDIATELY, logger = console } = opt;
// Special cases that are able to preserve async stack traces

@@ -48,4 +48,4 @@ // Special case: serial execution

}
// Special case: concurrency === Infinity or items.length <= concurrency
if (concurrency === Infinity || items.length <= concurrency) {
// Special case: items.length <= concurrency (including when concurrency === Infinity)
if (items.length <= concurrency) {
return await pMapAll(items, mapper, errorMode, logger);

@@ -52,0 +52,0 @@ }

@@ -7,7 +7,3 @@ import type { AbortableAsyncMapper, CommonLogger } from '..';

*
* Defaults to 16.
*
* It previously (and originally) defaulted to Infinity, which was later changed,
* because it's somewhat dangerous to run "infinite number of parallel promises".
* You can still emulate the old behavior by passing `Infinity`.
* Defaults to Infitity.
*/

@@ -14,0 +10,0 @@ concurrency?: number;

@@ -44,3 +44,3 @@ "use strict";

return []; // short circuit
const { concurrency = 16, errorMode = __1.ErrorMode.THROW_IMMEDIATELY, logger = console } = opt;
const { concurrency = Infinity, errorMode = __1.ErrorMode.THROW_IMMEDIATELY, logger = console } = opt;
// Special cases that are able to preserve async stack traces

@@ -51,4 +51,4 @@ // Special case: serial execution

}
// Special case: concurrency === Infinity or items.length <= concurrency
if (concurrency === Infinity || items.length <= concurrency) {
// Special case: items.length <= concurrency (including when concurrency === Infinity)
if (items.length <= concurrency) {
return await pMapAll(items, mapper, errorMode, logger);

@@ -55,0 +55,0 @@ }

{
"name": "@naturalcycles/js-lib",
"version": "14.219.0",
"version": "14.219.1",
"scripts": {

@@ -5,0 +5,0 @@ "prepare": "husky",

@@ -8,7 +8,3 @@ import type { AbortableAsyncMapper, CommonLogger } from '..'

*
* Defaults to 16.
*
* It previously (and originally) defaulted to Infinity, which was later changed,
* because it's somewhat dangerous to run "infinite number of parallel promises".
* You can still emulate the old behavior by passing `Infinity`.
* Defaults to Infitity.
*/

@@ -77,3 +73,3 @@ concurrency?: number

const { concurrency = 16, errorMode = ErrorMode.THROW_IMMEDIATELY, logger = console } = opt
const { concurrency = Infinity, errorMode = ErrorMode.THROW_IMMEDIATELY, logger = console } = opt

@@ -86,4 +82,4 @@ // Special cases that are able to preserve async stack traces

// Special case: concurrency === Infinity or items.length <= concurrency
if (concurrency === Infinity || items.length <= concurrency) {
// Special case: items.length <= concurrency (including when concurrency === Infinity)
if (items.length <= concurrency) {
return await pMapAll(items, mapper, errorMode, logger)

@@ -90,0 +86,0 @@ }

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