diff --git a/client/common/lib/directives/translation.ts b/client/common/lib/directives/translation.ts index a947b6be..65002c53 100644 --- a/client/common/lib/directives/translation.ts +++ b/client/common/lib/directives/translation.ts @@ -37,7 +37,6 @@ export class TranslationDirective extends AsyncDirective { .pipe(map(registerClientOptions => registerClientOptions.peertubeHelpers)) .subscribe((registerClientHelpers: RegisterClientHelpers) => { this._peertubeHelpers = registerClientHelpers - console.log(`we got PeertubeHelpers ! ${JSON.stringify(registerClientHelpers)}`) this._asyncUpdateTranslation().then(() => {}, () => {}) }) } @@ -51,22 +50,18 @@ export class TranslationDirective extends AsyncDirective { this._translatedValue = locId } - console.log('rendering') this._asyncUpdateTranslation().then(() => {}, () => {}) return this._internalRender() } private readonly _internalRender = (): unknown => { - console.log(`internalRender ${this._translatedValue}`) return this._allowUnsafeHTML ? html`${unsafeHTML(this._translatedValue)}` : this._translatedValue } private readonly _asyncUpdateTranslation = async (): Promise => { const newValue = await this._peertubeHelpers?.translate(this._localizationId) ?? '' - console.log(`asyncUpdateTranslation ${newValue}`) - if (newValue !== '' && newValue !== this._translatedValue) { this._translatedValue = newValue this.setValue(this._internalRender())