From f479685678406a5df864d89615b33d29085ebfc6 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 6 Apr 2021 11:35:56 +0200 Subject: Agnostic actor image storage --- .../src/app/shared/shared-main/video-channel/video-channel.model.ts | 4 ++-- .../src/app/shared/shared-main/video-channel/video-channel.service.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'client/src/app/shared/shared-main/video-channel') diff --git a/client/src/app/shared/shared-main/video-channel/video-channel.model.ts b/client/src/app/shared/shared-main/video-channel/video-channel.model.ts index 126e43cea..b4c3365a9 100644 --- a/client/src/app/shared/shared-main/video-channel/video-channel.model.ts +++ b/client/src/app/shared/shared-main/video-channel/video-channel.model.ts @@ -1,4 +1,4 @@ -import { Account as ServerAccount, Avatar, VideoChannel as ServerVideoChannel, ViewsPerDate } from '@shared/models' +import { Account as ServerAccount, ActorImage, VideoChannel as ServerVideoChannel, ViewsPerDate } from '@shared/models' import { Account } from '../account/account.model' import { Actor } from '../account/actor.model' @@ -51,7 +51,7 @@ export class VideoChannel extends Actor implements ServerVideoChannel { } } - updateAvatar (newAvatar: Avatar) { + updateAvatar (newAvatar: ActorImage) { this.avatar = newAvatar this.updateComputedAttributes() diff --git a/client/src/app/shared/shared-main/video-channel/video-channel.service.ts b/client/src/app/shared/shared-main/video-channel/video-channel.service.ts index eff3fad4d..3f9ef74fa 100644 --- a/client/src/app/shared/shared-main/video-channel/video-channel.service.ts +++ b/client/src/app/shared/shared-main/video-channel/video-channel.service.ts @@ -3,7 +3,7 @@ import { catchError, map, tap } from 'rxjs/operators' import { HttpClient, HttpParams } from '@angular/common/http' import { Injectable } from '@angular/core' import { ComponentPaginationLight, RestExtractor, RestService } from '@app/core' -import { Avatar, ResultList, VideoChannel as VideoChannelServer, VideoChannelCreate, VideoChannelUpdate } from '@shared/models' +import { ActorImage, ResultList, VideoChannel as VideoChannelServer, VideoChannelCreate, VideoChannelUpdate } from '@shared/models' import { environment } from '../../../../environments/environment' import { Account } from '../account' import { AccountService } from '../account/account.service' @@ -85,7 +85,7 @@ export class VideoChannelService { changeVideoChannelAvatar (videoChannelName: string, avatarForm: FormData) { const url = VideoChannelService.BASE_VIDEO_CHANNEL_URL + videoChannelName + '/avatar/pick' - return this.authHttp.post<{ avatar: Avatar }>(url, avatarForm) + return this.authHttp.post<{ avatar: ActorImage }>(url, avatarForm) .pipe(catchError(err => this.restExtractor.handleError(err))) } -- cgit v1.2.3