@socketsecurity/cli-with-sentry 0.15.61 → 0.15.63

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/utils.js CHANGED
@@ -2045,7 +2045,7 @@ function applyRange(refRange, version, style = 'preserve') {
2045
2045
  const {
2046
2046
  raw
2047
2047
  } = range;
2048
- const comparators = [...range.set].flat();
2048
+ const comparators = range.set.flat();
2049
2049
  const {
2050
2050
  length
2051
2051
  } = comparators;
@@ -2261,7 +2261,7 @@ async function addArtifactToAlertsMap(artifact, alertsByPurl, options) {
2261
2261
  }
2262
2262
  sockPkgAlerts = [
2263
2263
  // Sort CVE alerts by severity: critical, high, middle, then low.
2264
- ...[...highestForCve.values()].map(d => d.alert).sort(alertSeverityComparator), ...[...highestForUpgrade.values()].map(d => d.alert), ...unfixableAlerts];
2264
+ ...Array.from(highestForCve.values()).map(d => d.alert).sort(alertSeverityComparator), ...Array.from(highestForUpgrade.values()).map(d => d.alert), ...unfixableAlerts];
2265
2265
  } else {
2266
2266
  sockPkgAlerts.sort((a, b) => sorts.naturalCompare(a.type, b.type));
2267
2267
  }
@@ -2372,7 +2372,7 @@ function logAlertsMap(alertsMap, options) {
2372
2372
  ...options
2373
2373
  };
2374
2374
  const translations = getTranslations();
2375
- const sortedEntries = [...alertsMap.entries()].sort((a, b) => getAlertsSeverityOrder(a[1]) - getAlertsSeverityOrder(b[1]));
2375
+ const sortedEntries = Array.from(alertsMap.entries()).sort((a, b) => getAlertsSeverityOrder(a[1]) - getAlertsSeverityOrder(b[1]));
2376
2376
  const aboveTheFoldPurls = new Set();
2377
2377
  const viewableAlertsByPurl = new Map();
2378
2378
  const hiddenAlertsByPurl = new Map();
@@ -2436,7 +2436,7 @@ function logAlertsMap(alertsMap, options) {
2436
2436
  }
2437
2437
  }
2438
2438
  const mentionedPurlsWithHiddenAlerts = new Set();
2439
- for (let i = 0, prevAboveTheFold = true, entries = [...viewableAlertsByPurl.entries()], {
2439
+ for (let i = 0, prevAboveTheFold = true, entries = Array.from(viewableAlertsByPurl.entries()), {
2440
2440
  length
2441
2441
  } = entries; i < length; i += 1) {
2442
2442
  const {
@@ -2550,7 +2550,7 @@ async function extractPurlsFromPnpmLockfile(lockfile) {
2550
2550
  for (const pkgPath of Object.keys(packages)) {
2551
2551
  visit(pkgPath);
2552
2552
  }
2553
- return [...seen].map(p => idToNpmPurl(stripPnpmPeerSuffix(stripLeadingPnpmDepPathSlash(p))));
2553
+ return Array.from(seen).map(p => idToNpmPurl(stripPnpmPeerSuffix(stripLeadingPnpmDepPathSlash(p))));
2554
2554
  }
2555
2555
  function isPnpmDepPath(maybeDepPath) {
2556
2556
  return maybeDepPath.length > 0 && maybeDepPath.charCodeAt(0) === 47; /*'/'*/
@@ -3270,5 +3270,5 @@ exports.updateConfigValue = updateConfigValue;
3270
3270
  exports.validationFlags = validationFlags;
3271
3271
  exports.walkNestedMap = walkNestedMap;
3272
3272
  exports.writeSocketJson = writeSocketJson;
3273
- //# debugId=60ed5474-80e0-4b23-a970-ff949b67298d
3273
+ //# debugId=974aa7be-9dce-4bed-bdcc-4f8ebd2061fc
3274
3274
  //# sourceMappingURL=utils.js.map