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
{{ message }}
Repository navigation
"Copy here" and "New Folder" are offered at the root of a view-only space and fail #4357
I understand this is a bug report and questions should be posted in the Community Discussions
I searched issues and couldn’t find anything (or linked relevant results below)
Bug Description
At the root of a space where the user can only view, "Copy here" / "Move here" in the location picker and "New Folder" in the right-click menu are offered and then fail with a 403. In subfolders they're correctly disabled or hidden.
Cause: at a project space root the current folder is the space itself, and canCreate() of a space always returns true (packages/web-client/src/helpers/space/functions.ts). canUpload() right above it checks the graph permissions correctly.
Reproduction Steps
As admin, add dennis as "Can edit" to space A (with a file) and as "Can view" to space B
As dennis, open space A, file menu > "Copy to", go to space B and click "Copy here"
Open space B and right-click the empty area of the file list
Expected Outcome
"Copy here" / "Move here" are disabled at B's root and "New Folder" isn't offered, like in B's subfolders.
Actual Outcome
The button is enabled and the copy fails with "Failed to copy »…«". The right-click menu offers "New Folder", which fails with "Failed to create folder".
Activity