nextcloud / nextcloud/server

Option to disable the deletion of files within a subtree if the the folder is protected from deletion

Open
#45,308 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

0. Needs triage enhancement feature: sharing
Dominant language
PHP
Stars
36.9k
Forks
5.2k
Avg merge
2d 3h
Merged PRs (30d)
713

Description

If a folder that cannot be deleted is attempted to be deleted, the files in the subfolders will be deleted.

A way to prevent this would be nice.

The files should still be deleteable if they are manually deleted in the subfolder.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue does not name files, tests, or an entry point. Start by locating the server code that handles deletion of folders and their contents, then trace how protected folders are checked. Done means preventing descendant-file deletion when the parent folder is protected while preserving direct manual deletion within subfolders, with tests covering both cases.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.