Skip to content

[PS] Don't allow underscores in template file names #3559

@jenlampton

Description

@jenlampton

While working on a site, I just noticed that field template files with underscores in the field name worked, as well as those with hyphens. I only discovered this because in my theme there was a mix of hyphens and underscores, and that confused me. Why would both work?

Then thinking about it further, I thought, "Jeez, I bet that's expensive." Backdrop is probably doing a file-exists check twice for each theme hook suggestion!

We should fix that. But, it wouldn't be backwards-compatible, so tagging for 2.x.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions