diff options
Diffstat (limited to 'client/src/app/shared/shared-video-playlist/video-playlist.service.ts')
-rw-r--r-- | client/src/app/shared/shared-video-playlist/video-playlist.service.ts | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/client/src/app/shared/shared-video-playlist/video-playlist.service.ts b/client/src/app/shared/shared-video-playlist/video-playlist.service.ts index a3f1393ff..0a01af593 100644 --- a/client/src/app/shared/shared-video-playlist/video-playlist.service.ts +++ b/client/src/app/shared/shared-video-playlist/video-playlist.service.ts | |||
@@ -279,18 +279,18 @@ export class VideoPlaylistService { | |||
279 | } | 279 | } |
280 | 280 | ||
281 | listenToVideoPlaylistChange (videoId: number) { | 281 | listenToVideoPlaylistChange (videoId: number) { |
282 | if (this.videoExistsObservableCache[ videoId ]) { | 282 | if (this.videoExistsObservableCache[videoId]) { |
283 | return this.videoExistsObservableCache[ videoId ] | 283 | return this.videoExistsObservableCache[videoId] |
284 | } | 284 | } |
285 | 285 | ||
286 | const obs = this.videoExistsInPlaylistObservable | 286 | const obs = this.videoExistsInPlaylistObservable |
287 | .pipe( | 287 | .pipe( |
288 | map(existsResult => existsResult[ videoId ]), | 288 | map(existsResult => existsResult[videoId]), |
289 | filter(r => !!r), | 289 | filter(r => !!r), |
290 | tap(result => this.videoExistsCache[ videoId ] = result) | 290 | tap(result => this.videoExistsCache[videoId] = result) |
291 | ) | 291 | ) |
292 | 292 | ||
293 | this.videoExistsObservableCache[ videoId ] = obs | 293 | this.videoExistsObservableCache[videoId] = obs |
294 | return obs | 294 | return obs |
295 | } | 295 | } |
296 | 296 | ||