Add video channel account list
authorChocobozzz <me@florianbigard.com>
Wed, 25 Apr 2018 13:43:19 +0000 (15:43 +0200)
committerChocobozzz <me@florianbigard.com>
Wed, 25 Apr 2018 13:43:19 +0000 (15:43 +0200)
25 files changed:
client/src/app/+account/account-routing.module.ts
client/src/app/+account/account-video-channels/account-video-channels.component.html [new file with mode: 0644]
client/src/app/+account/account-video-channels/account-video-channels.component.scss [new file with mode: 0644]
client/src/app/+account/account-video-channels/account-video-channels.component.ts [new file with mode: 0644]
client/src/app/+account/account.component.html
client/src/app/+account/account.component.ts
client/src/app/+account/account.module.ts
client/src/app/menu/menu.component.html
client/src/app/menu/menu.component.ts
client/src/app/my-account/my-account-settings/my-account-settings.component.html
client/src/app/my-account/my-account-settings/my-account-settings.component.ts
client/src/app/shared/account/account.model.ts
client/src/app/shared/actor/actor.model.ts [new file with mode: 0644]
client/src/app/shared/shared.module.ts
client/src/app/shared/users/user.model.ts
client/src/app/shared/video-channel/video-channel.model.ts [new file with mode: 0644]
client/src/app/shared/video-channel/video-channel.service.ts [new file with mode: 0644]
client/src/app/shared/video/video.model.ts
client/src/app/videos/+video-watch/comment/video-comment-add.component.html
client/src/app/videos/+video-watch/comment/video-comment-add.component.ts
client/src/app/videos/+video-watch/comment/video-comment.component.html
client/src/app/videos/+video-watch/comment/video-comment.component.ts
client/src/app/videos/+video-watch/comment/video-comment.model.ts
client/src/app/videos/+video-watch/video-watch.component.html
client/src/app/videos/+video-watch/video-watch.component.ts

index 53410212190c6a08c035b0f0aca2090ef3e042ca..f72d8373fe98a762658a659dc0db35425d33e768 100644 (file)
@@ -3,7 +3,8 @@ import { RouterModule, Routes } from '@angular/router'
 import { MetaGuard } from '@ngx-meta/core'
 import { AccountComponent } from './account.component'
 import { AccountVideosComponent } from './account-videos/account-videos.component'
-import { AccountAboutComponent } from '@app/+account/account-about/account-about.component'
+import { AccountAboutComponent } from './account-about/account-about.component'
+import { AccountVideoChannelsComponent } from './account-video-channels/account-video-channels.component'
 
 const accountRoutes: Routes = [
   {
@@ -25,6 +26,15 @@ const accountRoutes: Routes = [
           }
         }
       },
+      {
+        path: 'video-channels',
+        component: AccountVideoChannelsComponent,
+        data: {
+          meta: {
+            title: 'Account video channels'
+          }
+        }
+      },
       {
         path: 'about',
         component: AccountAboutComponent,
diff --git a/client/src/app/+account/account-video-channels/account-video-channels.component.html b/client/src/app/+account/account-video-channels/account-video-channels.component.html
new file mode 100644 (file)
index 0000000..d20b40c
--- /dev/null
@@ -0,0 +1,11 @@
+<div *ngIf="account" class="row">
+  <a
+    *ngFor="let videoChannel of videoChannels" [routerLink]="[ '/video-channels', videoChannel.uuid ]"
+    class="video-channel" title="See this video channel"
+  >
+    <img [src]="videoChannel.avatarUrl" alt="Avatar" />
+
+    <div class="video-channel-display-name">{{ videoChannel.displayName }}</div>
+    <div class="video-channel-followers">{{ videoChannel.followersCount }} subscribers</div>
+  </a>
+</div>
\ No newline at end of file
diff --git a/client/src/app/+account/account-video-channels/account-video-channels.component.scss b/client/src/app/+account/account-video-channels/account-video-channels.component.scss
new file mode 100644 (file)
index 0000000..c9c7fa8
--- /dev/null
@@ -0,0 +1,30 @@
+@import '_variables';
+@import '_mixins';
+
+.row {
+  text-align: center;
+}
+
+a.video-channel {
+  @include disable-default-a-behaviour;
+
+  display: inline-block;
+  text-align: center;
+  color: #000;
+  margin: 10px 30px;
+
+  img {
+    @include avatar(80px);
+
+    margin-bottom: 10px;
+  }
+
+  .video-channel-display-name {
+    font-size: 20px;
+    font-weight: $font-bold;
+  }
+
+  .video-channel-followers {
+    font-size: 15px;
+  }
+}
\ No newline at end of file
diff --git a/client/src/app/+account/account-video-channels/account-video-channels.component.ts b/client/src/app/+account/account-video-channels/account-video-channels.component.ts
new file mode 100644 (file)
index 0000000..8915eb6
--- /dev/null
@@ -0,0 +1,33 @@
+import { Component, OnInit } from '@angular/core'
+import { ActivatedRoute } from '@angular/router'
+import 'rxjs/add/observable/from'
+import 'rxjs/add/operator/concatAll'
+import { Account } from '@app/shared/account/account.model'
+import { AccountService } from '@app/shared/account/account.service'
+import { VideoChannel } from '../../../../../shared/models/videos'
+import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
+
+@Component({
+  selector: 'my-account-video-channels',
+  templateUrl: './account-video-channels.component.html',
+  styleUrls: [ './account-video-channels.component.scss' ]
+})
+export class AccountVideoChannelsComponent implements OnInit {
+  account: Account
+  videoChannels: VideoChannel[] = []
+
+  constructor (
+    protected route: ActivatedRoute,
+    private accountService: AccountService,
+    private videoChannelService: VideoChannelService
+  ) { }
+
+  ngOnInit () {
+    // Parent get the account for us
+    this.accountService.accountLoaded
+        .do(account => this.account = account)
+        .flatMap(account => this.videoChannelService.getVideoChannels(account.id))
+        .map(res => res.data)
+        .subscribe(videoChannels => this.videoChannels = videoChannels)
+  }
+}
index f875b37a4226e8099c2830d2833158e3ce172b96..d0e99edda0e840e5c1700ec75ebda898f654524d 100644 (file)
@@ -2,7 +2,7 @@
   <div class="sub-menu">
 
     <div class="account">
-      <img [src]="getAvatarUrl()" alt="Avatar" />
+      <img [src]="account.avatarUrl" alt="Avatar" />
 
       <div class="account-info">
         <div class="account-display-name">{{ account.displayName }}</div>
@@ -13,6 +13,8 @@
     <div class="links">
       <a routerLink="videos" routerLinkActive="active" class="title-page">Videos</a>
 
+      <a routerLink="video-channels" routerLinkActive="active" class="title-page">Video channels</a>
+
       <a routerLink="about" routerLinkActive="active" class="title-page">About</a>
     </div>
   </div>
index ae5354ed9be710947f083d583a27deb090ffce62..d936ce2fe0d3ae8ac1ddd91971ba6d5eb62d4407 100644 (file)
@@ -22,8 +22,4 @@ export class AccountComponent implements OnInit {
     this.accountService.getAccount(accountId)
         .subscribe(account => this.account = account)
   }
-
-  getAvatarUrl () {
-    return Account.GET_ACCOUNT_AVATAR_URL(this.account)
-  }
 }
index 2fe67f3c590ae52fe6d7c60fcbc3da8b1a65df3e..82ef06e76d9129b42c93df5df9f6b7138a628ef7 100644 (file)
@@ -4,6 +4,7 @@ import { AccountRoutingModule } from './account-routing.module'
 import { AccountComponent } from './account.component'
 import { AccountVideosComponent } from './account-videos/account-videos.component'
 import { AccountAboutComponent } from './account-about/account-about.component'
+import { AccountVideoChannelsComponent } from './account-video-channels/account-video-channels.component'
 
 @NgModule({
   imports: [
@@ -14,6 +15,7 @@ import { AccountAboutComponent } from './account-about/account-about.component'
   declarations: [
     AccountComponent,
     AccountVideosComponent,
+    AccountVideoChannelsComponent,
     AccountAboutComponent
   ],
 
index 832cd9e78fdfd1bf9a953bb7f2dd6db4350f4610..e4cd40628c73b76cda39708be4cbc46b66aeaaf7 100644 (file)
@@ -1,7 +1,7 @@
 <menu>
   <div *ngIf="isLoggedIn" class="logged-in-block">
     <a routerLink="/account/settings">
-      <img [src]="getUserAvatarUrl()" alt="Avatar" />
+      <img [src]="user.accountAvatarUrl" alt="Avatar" />
     </a>
 
     <div class="logged-in-info">
index 1f66e37542e762dee76fcf558422773cd005196b..4c35bb3a51ebed4f9d9fdb7a2adc8ab2d6c5ae19 100644 (file)
@@ -51,10 +51,6 @@ export class MenuComponent implements OnInit {
     )
   }
 
-  getUserAvatarUrl () {
-    return this.user.getAvatarUrl()
-  }
-
   isRegistrationAllowed () {
     return this.serverService.getConfig().signup.allowed
   }
index 7ae27dc7510e52015430d1b37f9c6d18d0bf598a..e11d93c01d6aeacdd895634c0573036e81b12e2a 100644 (file)
@@ -1,5 +1,5 @@
 <div class="user">
-  <img [src]="getAvatarUrl()" alt="Avatar" />
+  <img [src]="user.accountAvatarUrl" alt="Avatar" />
 
   <div class="user-info">
     <div class="user-info-username">{{ user.username }}</div>
index 91420cc6fd1868c88c6996e3761eac9363404e91..06d1138e72979fb81915cbf335397c2b1ebabbd3 100644 (file)
@@ -42,10 +42,6 @@ export class MyAccountSettingsComponent implements OnInit {
       .subscribe(data => this.userVideoQuotaUsed = data.videoQuotaUsed)
   }
 
-  getAvatarUrl () {
-    return this.user.getAvatarUrl()
-  }
-
   changeAvatar () {
     const avatarfile = this.avatarfileInput.nativeElement.files[ 0 ]
 
index 10a70ac31abf46d0e3400c79b696f9ccb487efda..6a3c6451c420fe0bee8690a4e04149b177987d5d 100644 (file)
@@ -1,50 +1,14 @@
 import { Account as ServerAccount } from '../../../../../shared/models/actors/account.model'
-import { Avatar } from '../../../../../shared/models/avatars/avatar.model'
-import { getAbsoluteAPIUrl } from '../misc/utils'
+import { Actor } from '../actor/actor.model'
 
-export class Account implements ServerAccount {
-  id: number
-  uuid: string
-  url: string
-  name: string
+export class Account extends Actor implements ServerAccount {
   displayName: string
   description: string
-  host: string
-  followingCount: number
-  followersCount: number
-  createdAt: Date
-  updatedAt: Date
-  avatar: Avatar
-
-  static GET_ACCOUNT_AVATAR_URL (account: Account) {
-    const absoluteAPIUrl = getAbsoluteAPIUrl()
-
-    if (account && account.avatar) return absoluteAPIUrl + account.avatar.path
-
-    return window.location.origin + '/client/assets/images/default-avatar.png'
-  }
-
-  static CREATE_BY_STRING (accountName: string, host: string) {
-    const absoluteAPIUrl = getAbsoluteAPIUrl()
-    const thisHost = new URL(absoluteAPIUrl).host
-
-    if (host.trim() === thisHost) return accountName
-
-    return accountName + '@' + host
-  }
 
   constructor (hash: ServerAccount) {
-    this.id = hash.id
-    this.uuid = hash.uuid
-    this.url = hash.url
-    this.name = hash.name
+    super(hash)
+
     this.displayName = hash.displayName
     this.description = hash.description
-    this.host = hash.host
-    this.followingCount = hash.followingCount
-    this.followersCount = hash.followersCount
-    this.createdAt = new Date(hash.createdAt.toString())
-    this.updatedAt = new Date(hash.updatedAt.toString())
-    this.avatar = hash.avatar
   }
 }
diff --git a/client/src/app/shared/actor/actor.model.ts b/client/src/app/shared/actor/actor.model.ts
new file mode 100644 (file)
index 0000000..56ff780
--- /dev/null
@@ -0,0 +1,50 @@
+import { Actor as ActorServer } from '../../../../../shared/models/actors/actor.model'
+import { getAbsoluteAPIUrl } from '@app/shared/misc/utils'
+import { Avatar } from '../../../../../shared/models/avatars/avatar.model'
+
+export abstract class Actor implements ActorServer {
+  id: number
+  uuid: string
+  url: string
+  name: string
+  host: string
+  followingCount: number
+  followersCount: number
+  createdAt: Date
+  updatedAt: Date
+  avatar: Avatar
+
+  avatarUrl: string
+
+  static GET_ACTOR_AVATAR_URL (actor: { avatar: Avatar }) {
+    const absoluteAPIUrl = getAbsoluteAPIUrl()
+
+    if (actor && actor.avatar) return absoluteAPIUrl + actor.avatar.path
+
+    return window.location.origin + '/client/assets/images/default-avatar.png'
+  }
+
+  static CREATE_BY_STRING (accountName: string, host: string) {
+    const absoluteAPIUrl = getAbsoluteAPIUrl()
+    const thisHost = new URL(absoluteAPIUrl).host
+
+    if (host.trim() === thisHost) return accountName
+
+    return accountName + '@' + host
+  }
+
+  protected constructor (hash: ActorServer) {
+    this.id = hash.id
+    this.uuid = hash.uuid
+    this.url = hash.url
+    this.name = hash.name
+    this.host = hash.host
+    this.followingCount = hash.followingCount
+    this.followersCount = hash.followersCount
+    this.createdAt = new Date(hash.createdAt.toString())
+    this.updatedAt = new Date(hash.updatedAt.toString())
+    this.avatar = hash.avatar
+
+    this.avatarUrl = Actor.GET_ACTOR_AVATAR_URL(this)
+  }
+}
index 2178eebc815c201cfc6c64b6369783ece3e75bfc..20019e47ae75d4af31cae7784eeb49b09d7a50b3 100644 (file)
@@ -32,6 +32,7 @@ import { VideoFeedComponent } from './video/video-feed.component'
 import { VideoThumbnailComponent } from './video/video-thumbnail.component'
 import { VideoService } from './video/video.service'
 import { AccountService } from '@app/shared/account/account.service'
+import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
 
 @NgModule({
   imports: [
@@ -106,7 +107,8 @@ import { AccountService } from '@app/shared/account/account.service'
     UserService,
     VideoService,
     AccountService,
-    MarkdownService
+    MarkdownService,
+    VideoChannelService
   ]
 })
 export class SharedModule { }
index 2bdc48a1dc81a381ba0cda7915e7f0069aca296d..d4551de894b699fa7f358cbeda1bdae01fb17888 100644 (file)
@@ -1,6 +1,6 @@
-import { hasUserRight, User as UserServerModel, UserRight, UserRole, VideoChannel } from '../../../../../shared'
-import { Account } from '../account/account.model'
+import { Account, hasUserRight, User as UserServerModel, UserRight, UserRole, VideoChannel } from '../../../../../shared'
 import { NSFWPolicyType } from '../../../../../shared/models/videos/nsfw-policy.type'
+import { Actor } from '@app/shared/actor/actor.model'
 
 export type UserConstructorHash = {
   id: number,
@@ -25,6 +25,7 @@ export class User implements UserServerModel {
   account: Account
   videoChannels: VideoChannel[]
   createdAt: Date
+  accountAvatarUrl: string
 
   constructor (hash: UserConstructorHash) {
     this.id = hash.id
@@ -52,19 +53,23 @@ export class User implements UserServerModel {
     if (hash.createdAt !== undefined) {
       this.createdAt = hash.createdAt
     }
+
+    this.updateComputedAttributes()
   }
 
   hasRight (right: UserRight) {
     return hasUserRight(this.role, right)
   }
 
-  getAvatarUrl () {
-    return Account.GET_ACCOUNT_AVATAR_URL(this.account)
-  }
-
   patch (obj: UserServerModel) {
     for (const key of Object.keys(obj)) {
       this[key] = obj[key]
     }
+
+    this.updateComputedAttributes()
+  }
+
+  private updateComputedAttributes () {
+    this.accountAvatarUrl = Actor.GET_ACTOR_AVATAR_URL(this.account)
   }
 }
diff --git a/client/src/app/shared/video-channel/video-channel.model.ts b/client/src/app/shared/video-channel/video-channel.model.ts
new file mode 100644 (file)
index 0000000..01381ac
--- /dev/null
@@ -0,0 +1,23 @@
+import { VideoChannel as ServerVideoChannel } from '../../../../../shared/models/videos/video-channel.model'
+import { Actor } from '../actor/actor.model'
+
+export class VideoChannel extends Actor implements ServerVideoChannel {
+  displayName: string
+  description: string
+  support: string
+  isLocal: boolean
+  ownerAccount?: {
+    id: number
+    uuid: string
+  }
+
+  constructor (hash: ServerVideoChannel) {
+    super(hash)
+
+    this.displayName = hash.displayName
+    this.description = hash.description
+    this.support = hash.support
+    this.isLocal = hash.isLocal
+    this.ownerAccount = hash.ownerAccount
+  }
+}
diff --git a/client/src/app/shared/video-channel/video-channel.service.ts b/client/src/app/shared/video-channel/video-channel.service.ts
new file mode 100644 (file)
index 0000000..1f9088c
--- /dev/null
@@ -0,0 +1,36 @@
+import { Injectable } from '@angular/core'
+import 'rxjs/add/operator/catch'
+import 'rxjs/add/operator/map'
+import { Observable } from 'rxjs/Observable'
+import { RestExtractor } from '../rest/rest-extractor.service'
+import { RestService } from '../rest/rest.service'
+import { HttpClient } from '@angular/common/http'
+import { VideoChannel as VideoChannelServer } from '../../../../../shared/models/videos'
+import { AccountService } from '../account/account.service'
+import { ResultList } from '../../../../../shared'
+import { VideoChannel } from './video-channel.model'
+
+@Injectable()
+export class VideoChannelService {
+  constructor (
+    private authHttp: HttpClient,
+    private restExtractor: RestExtractor,
+    private restService: RestService
+  ) {}
+
+  getVideoChannels (accountId: number): Observable<ResultList<VideoChannel>> {
+    return this.authHttp.get<ResultList<VideoChannelServer>>(AccountService.BASE_ACCOUNT_URL + accountId + '/video-channels')
+               .map(res => this.extractVideoChannels(res))
+               .catch((res) => this.restExtractor.handleError(res))
+  }
+
+  private extractVideoChannels (result: ResultList<VideoChannelServer>) {
+    const videoChannels: VideoChannel[] = []
+
+    for (const videoChannelJSON of result.data) {
+      videoChannels.push(new VideoChannel(videoChannelJSON))
+    }
+
+    return { data: videoChannels, total: result.total }
+  }
+}
index 2e85f40eff008f9e1b9af60955e9b3c4182f6e65..f56eecaebef2bdd9eb1d700ba7d3b134f16cca30 100644 (file)
@@ -1,13 +1,14 @@
-import { Account } from '@app/shared/account/account.model'
 import { User } from '../'
 import { Video as VideoServerModel, VideoPrivacy } from '../../../../../shared'
 import { Avatar } from '../../../../../shared/models/avatars/avatar.model'
 import { VideoConstant } from '../../../../../shared/models/videos/video.model'
 import { getAbsoluteAPIUrl } from '../misc/utils'
 import { ServerConfig } from '../../../../../shared/models'
+import { Actor } from '@app/shared/actor/actor.model'
 
 export class Video implements VideoServerModel {
   by: string
+  accountAvatarUrl: string
   createdAt: Date
   updatedAt: Date
   publishedAt: Date
@@ -85,7 +86,8 @@ export class Video implements VideoServerModel {
     this.nsfw = hash.nsfw
     this.account = hash.account
 
-    this.by = Account.CREATE_BY_STRING(hash.account.name, hash.account.host)
+    this.by = Actor.CREATE_BY_STRING(hash.account.name, hash.account.host)
+    this.accountAvatarUrl = Actor.GET_ACTOR_AVATAR_URL(this.account)
   }
 
   isVideoNSFWForUser (user: User, serverConfig: ServerConfig) {
index e393daa79f7f220d9755132f4b784cf5897326a9..54d7286db5f5792b0711fec807dc9ac5f7d5dfce 100644 (file)
@@ -1,6 +1,6 @@
 <form novalidate [formGroup]="form" (ngSubmit)="formValidated()">
   <div class="avatar-and-textarea">
-    <img [src]="getUserAvatarUrl()" alt="Avatar" />
+    <img [src]="user.accountAvatarUrl" alt="Avatar" />
 
     <div class="form-group">
       <textarea placeholder="Add comment..." formControlName="text" [ngClass]="{ 'input-error': formErrors['text'] }"
index 731652fda4ba4a52a8f65430cae76d7874be5f18..d1ca1968be54385ea9ec8e3cdc3be7bbbe5ac396 100644 (file)
@@ -100,10 +100,6 @@ export class VideoCommentAddComponent extends FormReactive implements OnInit {
     return this.form.value['text']
   }
 
-  getUserAvatarUrl () {
-    return this.user.getAvatarUrl()
-  }
-
   private addCommentReply (commentCreate: VideoCommentCreate) {
     return this.videoCommentService
       .addCommentReply(this.video.id, this.parentComment.id, commentCreate)
index 8a649e88fe63ce80982e6d9fbf49dbf130bd12a5..06808ef808b15297173218a5821a62542bf282fb 100644 (file)
@@ -1,5 +1,5 @@
 <div class="root-comment">
-  <img [src]="getAvatarUrl(comment.account)" alt="Avatar" />
+  <img [src]="comment.accountAvatarUrl" alt="Avatar" />
 
   <div class="comment">
     <div *ngIf="highlightedComment === true" class="highlighted-comment">Highlighted comment</div>
index 26fc9d0b8c3ec9a730baf08bb75976e25f2b6d5a..e90008de9b603fb8cbf2a5972ae23b72eebc20b8 100644 (file)
@@ -1,11 +1,9 @@
 import { Component, EventEmitter, Input, OnChanges, OnInit, Output } from '@angular/core'
 import { LinkifierService } from '@app/videos/+video-watch/comment/linkifier.service'
 import * as sanitizeHtml from 'sanitize-html'
-import { Account as AccountInterface } from '../../../../../../shared/models/actors'
 import { UserRight } from '../../../../../../shared/models/users'
 import { VideoCommentThreadTree } from '../../../../../../shared/models/videos/video-comment.model'
 import { AuthService } from '../../../core/auth'
-import { Account } from '../../../shared/account/account.model'
 import { Video } from '../../../shared/video/video.model'
 import { VideoComment } from './video-comment.model'
 
@@ -80,10 +78,6 @@ export class VideoCommentComponent implements OnInit, OnChanges {
     this.resetReply.emit()
   }
 
-  getAvatarUrl (account: AccountInterface) {
-    return Account.GET_ACCOUNT_AVATAR_URL(account)
-  }
-
   isRemovableByUser () {
     return this.isUserLoggedIn() &&
       (
index 8fa02aee18e4ea0e3f28288a588ecc4841c448d2..fe591811eeae127578aeac9665c229b89430dd99 100644 (file)
@@ -1,6 +1,6 @@
-import { Account } from '@app/shared/account/account.model'
 import { Account as AccountInterface } from '../../../../../../shared/models/actors'
 import { VideoComment as VideoCommentServerModel } from '../../../../../../shared/models/videos/video-comment.model'
+import { Actor } from '@app/shared/actor/actor.model'
 
 export class VideoComment implements VideoCommentServerModel {
   id: number
@@ -14,6 +14,7 @@ export class VideoComment implements VideoCommentServerModel {
   account: AccountInterface
   totalReplies: number
   by: string
+  accountAvatarUrl
 
   constructor (hash: VideoCommentServerModel) {
     this.id = hash.id
@@ -27,6 +28,7 @@ export class VideoComment implements VideoCommentServerModel {
     this.account = hash.account
     this.totalReplies = hash.totalReplies
 
-    this.by = Account.CREATE_BY_STRING(this.account.name, this.account.host)
+    this.by = Actor.CREATE_BY_STRING(this.account.name, this.account.host)
+    this.accountAvatarUrl = Actor.GET_ACTOR_AVATAR_URL(this.account)
   }
 }
index 036d75d3ca2f298e401499355fd6f501a950de80..5d3361561b7c93bcf0232be0b7e727a9a5c66869 100644 (file)
@@ -24,7 +24,7 @@
           <div class="video-info-by">
             <a [routerLink]="[ '/account', video.account.id ]" title="Go the account page">
               <span>By {{ video.by }}</span>
-              <img [src]="getAvatarPath()" alt="Account avatar" />
+              <img [src]="video.accountAvatarUrl" alt="Account avatar" />
             </a>
           </div>
         </div>
index 4b0c495832833a3e7089aabdf4043b7c7c55b82b..615b969e5100959378dde22c52f662605b525262 100644 (file)
@@ -228,10 +228,6 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
     return this.video.isBlackistableBy(this.user)
   }
 
-  getAvatarPath () {
-    return Account.GET_ACCOUNT_AVATAR_URL(this.video.account)
-  }
-
   getVideoPoster () {
     if (!this.video) return ''