From 26526a8d64e8a5a206dda1497265be18c2076d01 Mon Sep 17 00:00:00 2001 From: Peter Maquiran Date: Wed, 17 Jan 2024 10:30:04 +0100 Subject: [PATCH] change message --- .../new-publication/new-publication.page.ts | 4 ++-- .../new-publication/new-publication.page.ts | 19 ++----------------- 2 files changed, 4 insertions(+), 19 deletions(-) diff --git a/src/app/pages/publications/new-publication/new-publication.page.ts b/src/app/pages/publications/new-publication/new-publication.page.ts index 249799d08..eadbd642b 100644 --- a/src/app/pages/publications/new-publication/new-publication.page.ts +++ b/src/app/pages/publications/new-publication/new-publication.page.ts @@ -441,7 +441,7 @@ export class NewPublicationPage implements OnInit { } else { - this.toastService._badRequest("É necessário adicionar anexo") + this.toastService._badRequest("É necessário adicionar uma imagem ou vídeo") } @@ -486,7 +486,7 @@ export class NewPublicationPage implements OnInit { } else { - this.toastService._badRequest("É necessário adicionar anexo") + this.toastService._badRequest("É necessário adicionar uma imagem ou vídeo") } } diff --git a/src/app/shared/publication/new-publication/new-publication.page.ts b/src/app/shared/publication/new-publication/new-publication.page.ts index 0ae3eccb3..ca2e93586 100644 --- a/src/app/shared/publication/new-publication/new-publication.page.ts +++ b/src/app/shared/publication/new-publication/new-publication.page.ts @@ -381,7 +381,7 @@ export class NewPublicationPage implements OnInit { } else { - this.toastService._badRequest("É necessário adicionar um anexo") + this.toastService._badRequest("É necessário adicionar uma imagem ou vídeo") } @@ -431,7 +431,7 @@ export class NewPublicationPage implements OnInit { } else { - this.toastService._badRequest("É necessário adicionar um anexo") + this.toastService._badRequest("É necessário adicionar uma imagem ou vídeo") } } @@ -963,26 +963,12 @@ class UploadFileUseCase { let path: string; const length = ChucksManager.chunks.totalChunks.toString() - function makeFrom({blobFile, index, path}) { - - const formData = new FormData(); - - formData.append("blobFile", blobFile); - formData.append("length", length); - formData.append("index", index.toString()); - formData.append("path", path); - - return formData - } - const readAndUploadChunk = async(index: number) => { const chunk = await ChucksManager.chunks.getChunks(index) const blob = new Blob([chunk]); const blobFile = new File([blob], "test.mp4", { type: blob.type }); - const form = makeFrom({blobFile, index, path}) - return await this.LakefsRepositoryService.FileContent({length, path, index, blobFile}) } @@ -992,7 +978,6 @@ class UploadFileUseCase { const chuck = await ChucksManager.chunks.getChunks(initIndex) const blob = new Blob([chuck]); const blobFile = new File([blob], "test.mp4", { type: blob.type }); - const form = makeFrom({blobFile, index: initIndex, path}) const uploadRequest = await this.LakefsRepositoryService.FileContent({length, path, index: initIndex, blobFile})