random bs
This commit is contained in:
parent
0e172dd73a
commit
c22eea56bd
@ -1,10 +1,10 @@
|
|||||||
|
/* eslint-disable no-control-regex */
|
||||||
const { transports: { File }} = require('winston');
|
const { transports: { File }} = require('winston');
|
||||||
const debug = require('diagnostics')('winston:file');
|
const debug = require('diagnostics')('winston:file');
|
||||||
const { MESSAGE } = require('triple-beam');
|
const { MESSAGE } = require('triple-beam');
|
||||||
const moment = require('moment');
|
const moment = require('moment');
|
||||||
const chalk = require('chalk');
|
|
||||||
|
|
||||||
const regex = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g
|
const regex = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
|
||||||
|
|
||||||
class FileExtension extends File {
|
class FileExtension extends File {
|
||||||
|
|
||||||
@ -38,7 +38,7 @@ class FileExtension extends File {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Grab the raw string and append the expected EOL.
|
// Grab the raw string and append the expected EOL.
|
||||||
const output = `${info[MESSAGE]}${this.eol}`.replace(regex, '')
|
const output = `${info[MESSAGE]}${this.eol}`.replace(regex, '');
|
||||||
const bytes = Buffer.byteLength(output);
|
const bytes = Buffer.byteLength(output);
|
||||||
|
|
||||||
// After we have written to the PassThrough check to see if we need
|
// After we have written to the PassThrough check to see if we need
|
||||||
|
Loading…
Reference in New Issue
Block a user