mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-11-23 10:16:32 -05:00
ConsoleLoggerService: Fix ESLint errors
We now use @types/cli-color to provide type information Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
a0ffa3be04
commit
b22d641406
3 changed files with 9 additions and 3 deletions
|
@ -58,6 +58,7 @@
|
|||
"@nestjs/cli": "7.5.6",
|
||||
"@nestjs/schematics": "7.2.8",
|
||||
"@nestjs/testing": "7.6.13",
|
||||
"@types/cli-color": "^2.0.0",
|
||||
"@types/express": "4.17.11",
|
||||
"@types/jest": "26.0.20",
|
||||
"@types/node": "13.13.45",
|
||||
|
|
|
@ -6,12 +6,12 @@
|
|||
|
||||
import { Injectable, Optional, Scope } from '@nestjs/common';
|
||||
import { isObject } from '@nestjs/common/utils/shared.utils';
|
||||
import * as clc from 'cli-color';
|
||||
import clc = require('cli-color');
|
||||
import DateTimeFormatOptions = Intl.DateTimeFormatOptions;
|
||||
|
||||
@Injectable({ scope: Scope.TRANSIENT })
|
||||
export class ConsoleLoggerService {
|
||||
private classContext;
|
||||
private classContext: string;
|
||||
private lastTimestamp: number;
|
||||
|
||||
constructor(@Optional() context?: string) {
|
||||
|
@ -68,7 +68,7 @@ export class ConsoleLoggerService {
|
|||
);
|
||||
}
|
||||
|
||||
private makeContextString(functionContext) {
|
||||
private makeContextString(functionContext: string) {
|
||||
let context = this.classContext;
|
||||
if (functionContext) {
|
||||
context += '.' + functionContext + '()';
|
||||
|
|
|
@ -846,6 +846,11 @@
|
|||
"@types/connect" "*"
|
||||
"@types/node" "*"
|
||||
|
||||
"@types/cli-color@^2.0.0":
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/@types/cli-color/-/cli-color-2.0.0.tgz#dc64e32da0fb9ea1814300fb468a58e833ce71a6"
|
||||
integrity sha512-E2Oisr73FjwxMHkYU6RcN9P9mmrbG4TNQMIebWhazYxOgWRzA7s4hM+DtAs6ZwiwKFbPst42v1XUAC1APIhRJA==
|
||||
|
||||
"@types/connect@*":
|
||||
version "3.4.34"
|
||||
resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.34.tgz#170a40223a6d666006d93ca128af2beb1d9b1901"
|
||||
|
|
Loading…
Reference in a new issue