Removed nslog and patching of console.log

This commit is contained in:
Maurício Szabo 2023-04-17 23:07:00 -03:00
parent c0c91c6b7e
commit e74a1de551
2 changed files with 2 additions and 7 deletions

View File

@ -6,6 +6,8 @@
## [Unreleased]
- Removed `nslog` dependency
## 1.104.0
- The settings-view package now lists a packages snippets more accurately

View File

@ -1,5 +1,4 @@
const { app } = require('electron');
const nslog = require('nslog');
const path = require('path');
const temp = require('temp');
const parseCommandLine = require('./parse-command-line');
@ -43,11 +42,6 @@ module.exports = function start(resourcePath, devResourcePath, startTime) {
const args = parseCommandLine(process.argv.slice(1));
// This must happen after parseCommandLine() because yargs uses console.log
// to display the usage message.
const previousConsoleLog = console.log;
console.log = nslog;
args.resourcePath = normalizeDriveLetterName(resourcePath);
args.devResourcePath = normalizeDriveLetterName(devResourcePath);
@ -67,7 +61,6 @@ module.exports = function start(resourcePath, devResourcePath, startTime) {
'userData',
temp.mkdirSync('atom-user-data-dir-for-main-process-tests')
);
console.log = previousConsoleLog;
app.on('ready', function() {
const testRunner = require(path.join(
args.resourcePath,