[MGNLRES-282] Don't delete parent folders when deleting a resource file Created: 10/Aug/16  Updated: 03/May/22  Resolved: 03/May/22

Status: Closed
Project: Magnolia Resources Module
Component/s: None
Affects Version/s: 2.4.6, 3.0
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Ngoc Nguyenthanh Assignee: Unassigned
Resolution: Won't Fix Votes: 1
Labels: resources-app
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File delete-resource-file-also-delete-its-parent-folders.png    
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:
Team: Nucleus

 Description   

Steps to reproduce:

  • Open Resource Files app
  • Create folders: /abc/abc
  • Create a file abc
  • Delete the file abc

Observation Result: the folder /abc and /abc/abc are deleted
Expected Result: Just delete the file only



 Comments   
Comment by Antti Hietala [ 23/Nov/16 ]

The item the user intends to delete doesn't have to be a file, it can also be a subfolder. And the parent doesn't need to have the same name. The issue still occurs. Reproducible on CORE 5.5.

Use case: The user makes a typo in a folder name. Since there is no rename action the user must delete the subfolder. Magnolia marks the whole folder structure for deletion.

Resource Files app
my-module/
└── decorations
    └── poges    <--- Oops, typo. Delete this subfolder and the whole hierarchy is deleted.
Generated at Mon Feb 12 06:49:10 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.