fix message space on video upload cancel
authorRigel Kent <sendmemail@rigelk.eu>
Sat, 29 Sep 2018 00:42:45 +0000 (02:42 +0200)
committerRigel Kent <sendmemail@rigelk.eu>
Sat, 29 Sep 2018 00:42:45 +0000 (02:42 +0200)
client/src/app/videos/+video-edit/video-add-components/video-upload.component.ts
client/src/app/videos/+video-edit/video-update.component.ts

index c1920b1f01c7618d8e7072e3a697fbfcbb8e4134..5844418171cc4aa5c52a707459e407d68f439567 100644 (file)
@@ -83,7 +83,7 @@ export class VideoUploadComponent extends VideoSend implements OnInit, OnDestroy
 
     if (this.videoUploaded === true) {
       // FIXME: cannot concatenate strings inside i18n service :/
-      text = this.i18n('Your video was uploaded to your account and is private.') +
+      text = this.i18n('Your video was uploaded to your account and is private.') + ' ' +
         this.i18n('But associated data (tags, description...) will be lost, are you sure you want to leave this page?')
     } else {
       text = this.i18n('Your video is not uploaded yet, are you sure you want to leave this page?')
index 856e61530f7582c3e2cfe9e98c1c5451a96a94bf..3a0f3a39aab093e0c39435746082333394c99c62 100644 (file)
@@ -93,7 +93,8 @@ export class VideoUpdateComponent extends FormReactive implements OnInit {
   }
 
   update () {
-    if (this.checkForm() === false) {
+    if (this.checkForm() === false
+      || this.isUpdatingVideo === true) {
       return
     }