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

log-segment

Package Overview
Dependencies
Maintainers
1
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

log-segment - npm Package Compare versions

Comparing version 1.3.2 to 1.4.0

20

main.js

@@ -114,2 +114,22 @@ 'use strict'

}
if (params.disabled) {
if (Array.isArray(params.disabled.segments) && __enabled.segments) {
if (__enabled.segments === '*') {
__enabled.segments = Object.keys(__segments)
}
__enabled.segments = __enabled.segments.filter((segment) => {
return params.disabled.segments.indexOf(segment)
})
}
if (Array.isArray(params.disabled.levels) && __enabled.levels) {
if (__enabled.levels === '*') {
__enabled.levels = Object.keys(__levels)
}
__enabled.levels = __enabled.levels.filter((level) => {
return params.disabled.levels.indexOf(level)
})
}
}
}

@@ -116,0 +136,0 @@

2

package.json
{
"name": "log-segment",
"version": "1.3.2",
"version": "1.4.0",
"description": "logger with partition",

@@ -5,0 +5,0 @@ "main": "main.js",

@@ -211,2 +211,9 @@ # log-segment

**Beta**
Enable all segments, disable info and success level
````js
log.set({ disabled: { levels: ['info', 'success'] } })
````
**Production**

@@ -213,0 +220,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