mirror of
https://github.com/CommunitySolidServer/CommunitySolidServer.git
synced 2024-10-03 14:55:10 +00:00
16 lines
481 B
TypeScript
16 lines
481 B
TypeScript
import type { Logger } from './Logger';
|
|
import type { LoggerFactory } from './LoggerFactory';
|
|
import { VoidLogger } from './VoidLogger';
|
|
|
|
/**
|
|
* A factory that always returns {@link VoidLogger}, which does nothing on log messages.
|
|
*/
|
|
export class VoidLoggerFactory implements LoggerFactory {
|
|
private readonly logger = new VoidLogger();
|
|
|
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
public createLogger(label: string): Logger {
|
|
return this.logger;
|
|
}
|
|
}
|