chore: update remove file function logic (#1259)

* chore: update remove file function logic

* fix: workspace file delete endpoint
This commit is contained in:
Aaryan Khandelwal 2023-06-09 10:24:57 +05:30 committed by GitHub
parent d09f410f21
commit e7af3da115
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 18 additions and 24 deletions

View file

@ -111,10 +111,7 @@ const WorkspaceSettings: NextPage = () => {
setIsImageRemoving(true);
const index = url.indexOf(".com");
const asset = url.substring(index + 5);
fileService.deleteFile(asset).then(() => {
fileService.deleteFile(activeWorkspace.id, url).then(() => {
workspaceService
.updateWorkspace(activeWorkspace.slug, { logo: "" }, user)
.then((res) => {