]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Fix adding captions to a video
authorChocobozzz <me@florianbigard.com>
Mon, 17 Dec 2018 12:38:01 +0000 (13:38 +0100)
committerChocobozzz <me@florianbigard.com>
Mon, 17 Dec 2018 12:38:01 +0000 (13:38 +0100)
client/src/app/videos/+video-edit/shared/video-caption-add-modal.component.ts

index eaf8197264366e49bfb54e960f33eb0f44113467..1413e7262b6d01f5bc012d864c2c3dd6071d91f2 100644 (file)
@@ -72,8 +72,6 @@ export class VideoCaptionAddModalComponent extends FormReactive implements OnIni
   }
 
   async addCaption () {
-    this.hide()
-
     const languageId = this.form.value[ 'language' ]
     const languageObject = this.videoCaptionLanguages.find(l => l.id === languageId)
 
@@ -82,6 +80,6 @@ export class VideoCaptionAddModalComponent extends FormReactive implements OnIni
       captionfile: this.form.value[ 'captionfile' ]
     })
 
-    this.form.reset()
+    this.hide()
   }
 }