You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Current Behavior
Admins can delete their files and other member's, but members cannot delete their own. A file deleted by an admin also remains in the media manager view until the page is reloaded.
Steps to Reproduce
Go to /admin#/extension/fof-upload as an admin and give the Member role permissions to Upload, View and Delete files.
Go to /u/<me>/uploads as a Member.
A delete button has appeared near each file. Clicking on said button results in 403 error.
Hi @nxmndr thanks for the bug report! Are you able to reproduce the permission issue when only fof/upload is enabled (besides the Flarum 1st party extensions)?
Regarding the page reload being required; in this sense it's not really a bug, but a feature which would have to be implemented. A web socket connection would be required for this to work, which could optionally be supported (for example with blomstra/realtime). Currently, this isn't a very high priority, but PRs are always welcome!
A websocket ? I don't mean the user seing changes made by admin instantly, I mean the admin not seing the result of the deletion they made themselves as in click => nothing happens on the screen. I'm still new to Flarum but I think calling GET /api/fof/uploads once POST /api/fof/upload/delete is done would be enough (might even include it in the POST result).
Bug Report
Current Behavior
Admins can delete their files and other member's, but members cannot delete their own. A file deleted by an admin also remains in the media manager view until the page is reloaded.
Steps to Reproduce
/admin#/extension/fof-upload
as an admin and give the Member role permissions to Upload, View and Delete files./u/<me>/uploads
as a Member.See call stack
Expected Behavior
Having the Delete permission as a member should allow to delete one's own files.
They should also disappear from the view without requiring page reload.
Environment
Output of "php flarum info"
Possible solution(s)
I believe there should be additional View and Delete permissions for other users files.
Best
The text was updated successfully, but these errors were encountered: