diff options
author | Chocobozzz <me@florianbigard.com> | 2023-05-24 16:48:54 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2023-05-24 16:56:05 +0200 |
commit | 54909304287f3c04dcfb39660be8ead57dc95440 (patch) | |
tree | 478f1b913f3bd4c3bbaa17525f0114c5b0a8689d /client/src/app/shared/shared-actor-image | |
parent | d0fbc9fd0a29c37f3ff9b99030351e90b276fe7d (diff) | |
download | PeerTube-54909304287f3c04dcfb39660be8ead57dc95440.tar.gz PeerTube-54909304287f3c04dcfb39660be8ead57dc95440.tar.zst PeerTube-54909304287f3c04dcfb39660be8ead57dc95440.zip |
Remove suppressImplicitAnyIndexErrors
It's deprecated by TS
Diffstat (limited to 'client/src/app/shared/shared-actor-image')
-rw-r--r-- | client/src/app/shared/shared-actor-image/actor-avatar.component.ts | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/client/src/app/shared/shared-actor-image/actor-avatar.component.ts b/client/src/app/shared/shared-actor-image/actor-avatar.component.ts index f1c1aa03f..ab2e02ad7 100644 --- a/client/src/app/shared/shared-actor-image/actor-avatar.component.ts +++ b/client/src/app/shared/shared-actor-image/actor-avatar.component.ts | |||
@@ -1,6 +1,7 @@ | |||
1 | import { Component, Input, OnChanges, OnInit } from '@angular/core' | 1 | import { Component, Input, OnChanges, OnInit } from '@angular/core' |
2 | import { VideoChannel } from '../shared-main' | 2 | import { VideoChannel } from '../shared-main' |
3 | import { Account } from '../shared-main/account/account.model' | 3 | import { Account } from '../shared-main/account/account.model' |
4 | import { objectKeysTyped } from '@shared/core-utils' | ||
4 | 5 | ||
5 | type ActorInput = { | 6 | type ActorInput = { |
6 | name: string | 7 | name: string |
@@ -154,8 +155,8 @@ export class ActorAvatarComponent implements OnInit, OnChanges { | |||
154 | 'wxyz': 'dark-blue' | 155 | 'wxyz': 'dark-blue' |
155 | } | 156 | } |
156 | 157 | ||
157 | const theme = Object.keys(themes) | 158 | const theme = objectKeysTyped(themes) |
158 | .find(chars => chars.includes(initialLowercase)) | 159 | .find(chars => chars.includes(initialLowercase)) |
159 | 160 | ||
160 | return themes[theme] || 'blue' | 161 | return themes[theme] || 'blue' |
161 | } | 162 | } |