From 3d7ecbd7f2e9c9faba607816a5ff1df6c3994111 Mon Sep 17 00:00:00 2001 From: Alexander Bukhalo Date: Sat, 2 Jan 2021 01:32:49 +0300 Subject: [PATCH] chore(): cleanup debug code --- lib/services/updates-explorer.service.ts | 5 +---- lib/telegraf-core.module.ts | 7 +------ 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/lib/services/updates-explorer.service.ts b/lib/services/updates-explorer.service.ts index 31d4325..f1d785c 100644 --- a/lib/services/updates-explorer.service.ts +++ b/lib/services/updates-explorer.service.ts @@ -1,4 +1,4 @@ -import { Inject, Injectable, Logger, OnModuleInit } from '@nestjs/common'; +import { Inject, Injectable, OnModuleInit } from '@nestjs/common'; import { DiscoveryService, ModuleRef, ModulesContainer } from '@nestjs/core'; import { InstanceWrapper } from '@nestjs/core/injector/instance-wrapper'; import { MetadataScanner } from '@nestjs/core/metadata-scanner'; @@ -29,8 +29,6 @@ import { Module } from '@nestjs/core/injector/module'; export class UpdatesExplorerService extends BaseExplorerService implements OnModuleInit { - private readonly logger = new Logger(UpdatesExplorerService.name); - constructor( @Inject(TELEGRAF_BOT_NAME) private readonly botName: string, @@ -48,7 +46,6 @@ export class UpdatesExplorerService private bot: Telegraf; onModuleInit(): void { - this.logger.debug(this.botName); this.bot = this.moduleRef.get>(this.botName, { strict: false, }); diff --git a/lib/telegraf-core.module.ts b/lib/telegraf-core.module.ts index 7cf3703..25f0e8f 100644 --- a/lib/telegraf-core.module.ts +++ b/lib/telegraf-core.module.ts @@ -7,7 +7,6 @@ import { Global, Inject, OnApplicationShutdown, - Logger, } from '@nestjs/common'; import { TelegrafModuleOptions, @@ -29,14 +28,10 @@ import { defer } from 'rxjs'; providers: [UpdatesExplorerService, MetadataAccessorService], }) export class TelegrafCoreModule implements OnApplicationShutdown { - private readonly logger = new Logger(TelegrafCoreModule.name); - constructor( @Inject(TELEGRAF_BOT_NAME) private readonly botName: string, private readonly moduleRef: ModuleRef, - ) { - this.logger.debug(botName); - } + ) {} public static forRoot(options: TelegrafModuleOptions): DynamicModule { const telegrafBotName = getBotToken(options.botName);