]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/shared/shared-main/account/account.model.ts
Autoclose settings on outside click
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-main / account / account.model.ts
index b71a893d1111b53a6c826df1a9319e68d3d43651..65e6798d44decf2badb892bb3d7e3aa6f14fef35 100644 (file)
@@ -1,4 +1,4 @@
-import { Account as ServerAccount, Avatar } from '@shared/models'
+import { Account as ServerAccount, Actor as ServerActor, ActorImage } from '@shared/models'
 import { Actor } from './actor.model'
 
 export class Account extends Actor implements ServerAccount {
@@ -13,7 +13,7 @@ export class Account extends Actor implements ServerAccount {
 
   userId?: number
 
-  static GET_ACTOR_AVATAR_URL (actor: object) {
+  static GET_ACTOR_AVATAR_URL (actor: { avatar?: { url?: string, path: string } }) {
     return Actor.GET_ACTOR_AVATAR_URL(actor) || this.GET_DEFAULT_AVATAR_URL()
   }
 
@@ -38,7 +38,7 @@ export class Account extends Actor implements ServerAccount {
     this.mutedServerByInstance = false
   }
 
-  updateAvatar (newAvatar: Avatar) {
+  updateAvatar (newAvatar: ActorImage) {
     this.avatar = newAvatar
 
     this.updateComputedAttributes()