From 672e185bf3004b46552c227483ffd2802ebf6844 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 28 Oct 2022 11:19:45 +0200 Subject: Fix upload error handling --- .../+video-edit/video-add-components/video-upload.component.html | 6 ++---- .../+video-edit/video-add-components/video-upload.component.scss | 6 ------ .../+video-edit/video-add-components/video-upload.component.ts | 2 +- 3 files changed, 3 insertions(+), 11 deletions(-) (limited to 'client/src') diff --git a/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.html b/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.html index 8541868c5..779d42e0c 100644 --- a/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.html +++ b/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.html @@ -76,10 +76,8 @@ -
- - -
+ +
diff --git a/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.scss b/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.scss index 35c626ec2..52a77f83f 100644 --- a/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.scss +++ b/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.scss @@ -42,10 +42,4 @@ } } } - - input { - @include peertube-button; - @include grey-button; - @include margin-left(10px); - } } diff --git a/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.ts b/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.ts index b0d846664..967fa9ed1 100644 --- a/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.ts +++ b/client/src/app/+videos/+video-edit/video-add-components/video-upload.component.ts @@ -136,7 +136,7 @@ export class VideoUploadComponent extends VideoSend implements OnInit, OnDestroy onUploadVideoOngoing (state: UploadState) { switch (state.status) { case 'error': { - if (!this.alreadyRefreshedToken && state.response.status === HttpStatusCode.UNAUTHORIZED_401) { + if (!this.alreadyRefreshedToken && state.responseStatus === HttpStatusCode.UNAUTHORIZED_401) { this.alreadyRefreshedToken = true return this.refereshTokenAndRetryUpload() -- cgit v1.2.3