U4-864 - When creating an XSLT file with same name as an existing one, the old one is overwritten.

Created by Josiah Thoen 15 Sep 2012, 17:04:35 Updated by Sebastiaan Janssen 31 Jan 2013, 16:06:00

Relates to: U4-663

Subtask of: U4-760

To reproduce, Create and modify an XSLT file. Create a new one with the same name. The original one is now gone. Duplicate macros are created.

1 Attachments

Download 2776.patch


Josiah Thoen 15 Sep 2012, 17:05:38

Also, duplicate macros get created.

Sebastiaan Janssen 23 Oct 2012, 18:10:25

In the Save() event of src\Umbraco.Web\umbraco.presentation\umbraco\create\XsltTasks.cs, make sure the file doesn't yet exist, if it does, don't recreate it and don't recreate the macro.

Tim Payne 25 Oct 2012, 14:27:08

Attached patch fixes this, if you try to create an XSLT file with the same name as the existing one, you are redirected to the existing item rather than creating a new one.

Have also fixed the same issue in Javascript, Stylesheets, Macros and Scripting Files.

Sebastiaan Janssen 31 Oct 2012, 13:08:53

PAtch applied, changeset 5d25867e7ba2

Priority: Normal

Type: Bug

State: Fixed


Difficulty: Easy


Backwards Compatible: True

Fix Submitted: Patch

Affected versions: 4.9.0

Due in version: 4.10.0


Story Points: