Skip to content
This repository has been archived by the owner on Sep 13, 2022. It is now read-only.

How to remove / delete a uploaded file from mattermost-server ? #777

Open
vishnusadanandan opened this issue Feb 18, 2019 · 2 comments
Open

Comments

@vishnusadanandan
Copy link

Submit feature requests to http://www.mattermost.org/feature-requests/. File non-security related bugs here in the following format:

Summary

How to remove / delete a uploaded file from mattermost-server ?

Environment Information

  • Webapp or React Native app: Webapp
  • Mattermost Server Version:4.5.

Steps to reproduce

Upload file
mattermostClient.uploadFile(imageFormData)
Get file
mattermostClient.getFile(fileId)

There is function available for delete the file

Expected behavior

Upload file
mattermostClient.uploadFile(imageFormData)
Get file
mattermostClient.getFile(fileId)
Remove file
mattermostClient.removeFile(fileId)

Observed behavior

There is no function to do this task.

Possible fixes

If you can, link to the line of code that might be responsible for the problem.

@amyblais
Copy link
Member

Hi @vishnusadanandan,

This is probably a feature request and there are some related existing ones here:

I think one way to delete files is by deleting the post that contains the attachment.

@DareDareHub
Copy link

@amyblais
unfortunately files are not deleted on the server side when the post that contains them is deleted...

there should be a way to delete files or even multiple files at once and also channel...

in the 1st link above I think that resumes well the situation :
""The problem is that currently the mattermost installation will grow indefinitely.""

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants