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

@lokalise/node-core

Package Overview
Dependencies
Maintainers
11
Versions
107
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@lokalise/node-core - npm Package Compare versions

Comparing version 6.2.0 to 6.3.0

1

dist/src/errors/globalErrorHandler.d.ts

@@ -12,1 +12,2 @@ export declare const globalLogger: import("pino").Logger<import("pino").LoggerOptions | import("pino").DestinationStream>;

export declare function executeAsyncAndHandleGlobalErrors<T>(operation: () => Promise<T>, stopOnError?: boolean): Promise<T | undefined>;
export declare function executeSettleAllAndHandleGlobalErrors(promises: Promise<unknown>[], stopOnError?: boolean): Promise<PromiseSettledResult<unknown>[]>;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.executeAsyncAndHandleGlobalErrors = exports.executeAndHandleGlobalErrors = exports.resolveGlobalErrorLogObject = exports.globalLogger = void 0;
exports.executeSettleAllAndHandleGlobalErrors = exports.executeAsyncAndHandleGlobalErrors = exports.executeAndHandleGlobalErrors = exports.resolveGlobalErrorLogObject = exports.globalLogger = void 0;
const node_util_1 = require("node:util");

@@ -47,2 +47,18 @@ const pino_1 = require("pino");

exports.executeAsyncAndHandleGlobalErrors = executeAsyncAndHandleGlobalErrors;
async function executeSettleAllAndHandleGlobalErrors(promises, stopOnError = true) {
const result = await Promise.allSettled(promises);
let errorsHappened;
for (const entry of result) {
if (entry.status === 'rejected') {
const logObject = resolveGlobalErrorLogObject(entry.reason);
exports.globalLogger.error(logObject);
errorsHappened = true;
}
}
if (stopOnError && errorsHappened) {
process.exit(1);
}
return result;
}
exports.executeSettleAllAndHandleGlobalErrors = executeSettleAllAndHandleGlobalErrors;
//# sourceMappingURL=globalErrorHandler.js.map

2

package.json
{
"name": "@lokalise/node-core",
"version": "6.2.0",
"version": "6.3.0",
"author": {

@@ -5,0 +5,0 @@ "name": "Lokalise",

Sorry, the diff of this file is not supported yet

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