Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
MAJOR PROBLEM with use of static files in 2.7.0 #14188
It's no longer possible to duplicate an existing template, snippet, etc. when these use static files. An error pops up saying there is already a template, snippet, etc. that uses the particular static file name.
Step to reproduce
Create a template that uses a static file. Then, open that template and click the "Duplicate" button. Nothing happens. No warning, nothing. Right-click on the template in the tree and select duplicate, and the usual popup appears, but the Static File field is outlined in red, and the error below says the file already exists. It's impossible to save the new template without changing the name of the file.
I often create templates that share a common static file, because I use the template to control what TVs appear in the layout for different types of content. My base template is set up to be shared so that I don't end up with a slew of templates that all have the same code in them. The alert is fine, but it should be a warning and not prevent people from creating elements that share the same static file.
Furthermore, for things like snippets (where you wouldn't actually want them to share a common file), the Duplicate button should bring up the same popup with the option to specify a new file, instead of just doing nothing at all.