Skip to content

Commit

Permalink
fix(deps): remove vulnerability by updating log4js (#3372)
Browse files Browse the repository at this point in the history
  • Loading branch information
nicojs committed Jan 23, 2022
1 parent 8b5455c commit 69290f2
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
"inquirer": "~8.2.0",
"lodash.flatmap": "~4.5.0",
"lodash.groupby": "~4.6.0",
"log4js": "~6.2.1",
"log4js": "~6.4.1",
"minimatch": "~3.0.4",
"mkdirp": "~1.0.3",
"mutation-testing-elements": "1.7.8",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/logging/log-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import log4js from 'log4js';
* @param b other log level
*/
export function minLevel(a: LogLevel, b: LogLevel): LogLevel {
if (log4js.levels.getLevel(b).isGreaterThanOrEqualTo(log4js.levels.getLevel(a))) {
if (log4js.levels.getLevel(b, log4js.levels.INFO).isGreaterThanOrEqualTo(log4js.levels.getLevel(a, log4js.levels.INFO))) {
return a;
} else {
return b;
Expand Down
1 change: 1 addition & 0 deletions packages/core/test/helpers/producers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ export function createCheckerPoolMock(): sinon.SinonStubbedInstance<I<Pool<Check

export const logger = (): Mock<Logger> => {
return {
category: 'foo-category',
_log: sinon.stub(),
addContext: sinon.stub(),
clearContext: sinon.stub(),
Expand Down

0 comments on commit 69290f2

Please sign in to comment.