diff options
Diffstat (limited to 'client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts')
-rw-r--r-- | client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts | 8 |
1 files changed, 4 insertions, 4 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 875911b91..98d66ff00 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 | |||
@@ -66,18 +66,18 @@ export class VideoCaptionAddModalComponent extends FormReactive implements OnIni | |||
66 | isReplacingExistingCaption () { | 66 | isReplacingExistingCaption () { |
67 | if (this.closingModal === true) return false | 67 | if (this.closingModal === true) return false |
68 | 68 | ||
69 | const languageId = this.form.value[ 'language' ] | 69 | const languageId = this.form.value['language'] |
70 | 70 | ||
71 | return languageId && this.existingCaptions.indexOf(languageId) !== -1 | 71 | return languageId && this.existingCaptions.includes(languageId) |
72 | } | 72 | } |
73 | 73 | ||
74 | async addCaption () { | 74 | async 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 | ||
78 | this.captionAdded.emit({ | 78 | this.captionAdded.emit({ |
79 | language: languageObject, | 79 | language: languageObject, |
80 | captionfile: this.form.value[ 'captionfile' ] | 80 | captionfile: this.form.value['captionfile'] |
81 | }) | 81 | }) |
82 | 82 | ||
83 | this.hide() | 83 | this.hide() |