Socket
Socket
Sign inDemoInstall

electron-log

Package Overview
Dependencies
Maintainers
1
Versions
152
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

electron-log - npm Package Compare versions

Comparing version 4.4.7 to 4.4.8

2

package.json
{
"name": "electron-log",
"version": "4.4.7",
"version": "4.4.8",
"description": "Just a very simple logging module for your Electron application",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -247,3 +247,5 @@ import { RequestOptions } from 'http';

*/
readAllLogs(): Array<{ path: string, lines: string[] }>;
readAllLogs(
options?: { fileFilter?: (logPath: string) => boolean }
): Array<{ path: string, lines: string[] }>;

@@ -250,0 +252,0 @@ /**

@@ -117,3 +117,7 @@ 'use strict';

function readAllLogs() {
function readAllLogs(options) {
var fileFilter = options && typeof options.fileFilter === 'function'
? options.fileFilter
: function (fileName) { return fileName.endsWith('.log') };
var vars = Object.assign({}, pathVariables, {

@@ -125,4 +129,5 @@ fileName: transport.fileName,

return fs.readdirSync(logsPath)
.map(function (fileName) {
var logPath = path.join(logsPath, fileName);
.map(function (fileName) { return path.join(logsPath, fileName) })
.filter(fileFilter)
.map(function (logPath) {
try {

@@ -129,0 +134,0 @@ return {

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