X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=client%2Fsrc%2Fapp%2Fshared%2Fshared-forms%2Fpreview-upload.component.ts;h=edee6786db722df8733972093a2b76be3c95e614;hb=2989628b7913383b39ac34c7db8666a21f8e5037;hp=a55dcdd9a636671ab80ead85383173ccfa79d13a;hpb=8e08d415f9473b6b72fef698729453e726da16e7;p=github%2FChocobozzz%2FPeerTube.git diff --git a/client/src/app/shared/shared-forms/preview-upload.component.ts b/client/src/app/shared/shared-forms/preview-upload.component.ts index a55dcdd9a..edee6786d 100644 --- a/client/src/app/shared/shared-forms/preview-upload.component.ts +++ b/client/src/app/shared/shared-forms/preview-upload.component.ts @@ -2,7 +2,7 @@ import { Component, forwardRef, Input, OnInit } from '@angular/core' import { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms' import { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser' import { ServerService } from '@app/core' -import { ServerConfig } from '@shared/models' +import { HTMLServerConfig } from '@shared/models' import { BytesPipe } from '../shared-main' @Component({ @@ -27,7 +27,7 @@ export class PreviewUploadComponent implements OnInit, ControlValueAccessor { allowedExtensionsMessage = '' maxSizeText: string - private serverConfig: ServerConfig + private serverConfig: HTMLServerConfig private bytesPipe: BytesPipe private file: Blob @@ -52,9 +52,7 @@ export class PreviewUploadComponent implements OnInit, ControlValueAccessor { } ngOnInit () { - this.serverConfig = this.serverService.getTmpConfig() - this.serverService.getConfig() - .subscribe(config => this.serverConfig = config) + this.serverConfig = this.serverService.getHTMLConfig() this.allowedExtensionsMessage = this.videoImageExtensions.join(', ') }