aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+videos
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-08-25 16:14:11 +0200
committerChocobozzz <me@florianbigard.com>2021-08-26 10:01:42 +0200
commit98ab5dc81048d47d08a231f17698128f959e59b2 (patch)
tree7f74f835dc35d9f72918c56857f7f28b70d7053f /client/src/app/+videos
parent851675c5591dcab1070183f0ed1b1a788de07d2c (diff)
downloadPeerTube-98ab5dc81048d47d08a231f17698128f959e59b2.tar.gz
PeerTube-98ab5dc81048d47d08a231f17698128f959e59b2.tar.zst
PeerTube-98ab5dc81048d47d08a231f17698128f959e59b2.zip
Remove useless async
Diffstat (limited to 'client/src/app/+videos')
-rw-r--r--client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts2
-rw-r--r--client/src/app/+videos/+video-edit/shared/video-edit.component.ts2
-rw-r--r--client/src/app/+videos/+video-watch/shared/information/privacy-concerns.component.ts3
-rw-r--r--client/src/app/+videos/+video-watch/video-watch.component.ts4
4 files changed, 6 insertions, 5 deletions
diff --git a/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts b/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts
index 98d66ff00..5c4152884 100644
--- a/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts
+++ b/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts
@@ -71,7 +71,7 @@ export class VideoCaptionAddModalComponent extends FormReactive implements OnIni
71 return languageId && this.existingCaptions.includes(languageId) 71 return languageId && this.existingCaptions.includes(languageId)
72 } 72 }
73 73
74 async addCaption () { 74 addCaption () {
75 const languageId = this.form.value['language'] 75 const languageId = this.form.value['language']
76 const languageObject = this.videoCaptionLanguages.find(l => l.id === languageId) 76 const languageObject = this.videoCaptionLanguages.find(l => l.id === languageId)
77 77
diff --git a/client/src/app/+videos/+video-edit/shared/video-edit.component.ts b/client/src/app/+videos/+video-edit/shared/video-edit.component.ts
index 366c93a79..bf7fdeeed 100644
--- a/client/src/app/+videos/+video-edit/shared/video-edit.component.ts
+++ b/client/src/app/+videos/+video-edit/shared/video-edit.component.ts
@@ -231,7 +231,7 @@ export class VideoEditComponent implements OnInit, OnDestroy {
231 this.sortVideoCaptions() 231 this.sortVideoCaptions()
232 } 232 }
233 233
234 async deleteCaption (caption: VideoCaptionEdit) { 234 deleteCaption (caption: VideoCaptionEdit) {
235 // Caption recovers his former state 235 // Caption recovers his former state
236 if (caption.action && this.initialVideoCaptions.includes(caption.language.id)) { 236 if (caption.action && this.initialVideoCaptions.includes(caption.language.id)) {
237 caption.action = undefined 237 caption.action = undefined
diff --git a/client/src/app/+videos/+video-watch/shared/information/privacy-concerns.component.ts b/client/src/app/+videos/+video-watch/shared/information/privacy-concerns.component.ts
index ef5c8ed87..b1e8bf989 100644
--- a/client/src/app/+videos/+video-watch/shared/information/privacy-concerns.component.ts
+++ b/client/src/app/+videos/+video-watch/shared/information/privacy-concerns.component.ts
@@ -21,8 +21,9 @@ export class PrivacyConcernsComponent implements OnInit {
21 private serverService: ServerService 21 private serverService: ServerService
22 ) { } 22 ) { }
23 23
24 async ngOnInit () { 24 ngOnInit () {
25 this.serverConfig = this.serverService.getHTMLConfig() 25 this.serverConfig = this.serverService.getHTMLConfig()
26
26 if ( 27 if (
27 isWebRTCDisabled() || 28 isWebRTCDisabled() ||
28 this.serverConfig.tracker.enabled === false || 29 this.serverConfig.tracker.enabled === false ||
diff --git a/client/src/app/+videos/+video-watch/video-watch.component.ts b/client/src/app/+videos/+video-watch/video-watch.component.ts
index 2007bdecb..acfd46a41 100644
--- a/client/src/app/+videos/+video-watch/video-watch.component.ts
+++ b/client/src/app/+videos/+video-watch/video-watch.component.ts
@@ -113,7 +113,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
113 return this.userService.getAnonymousUser() 113 return this.userService.getAnonymousUser()
114 } 114 }
115 115
116 async ngOnInit () { 116 ngOnInit () {
117 this.serverConfig = this.serverService.getHTMLConfig() 117 this.serverConfig = this.serverService.getHTMLConfig()
118 118
119 PeertubePlayerManager.initState() 119 PeertubePlayerManager.initState()
@@ -640,7 +640,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
640 } 640 }
641 641
642 if (oldVideo && oldVideo.id !== newVideo.id) { 642 if (oldVideo && oldVideo.id !== newVideo.id) {
643 await this.peertubeSocket.unsubscribeLiveVideos(oldVideo.id) 643 this.peertubeSocket.unsubscribeLiveVideos(oldVideo.id)
644 } 644 }
645 645
646 if (!newVideo.isLive) return 646 if (!newVideo.isLive) return