summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfago2013-01-22 17:09:21 (GMT)
committer fago2013-01-22 17:09:21 (GMT)
commit681a20d1c8a8cb209b2ae7afa6121276f8fb9a2f (patch)
treec9dacff414875cb373d15e509bf7c946eab234e5
parent0fb1486b55e1bfae075d5a9948b1de3df8224528 (diff)
Issue #1462772: Follow-up to improve the pattern introduced by the last commit.
-rw-r--r--entity.module6
1 files changed, 3 insertions, 3 deletions
diff --git a/entity.module b/entity.module
index ef3e7be..3e7a2de 100644
--- a/entity.module
+++ b/entity.module
@@ -960,13 +960,13 @@ function entity_flush_caches() {
* Implements hook_theme().
*/
function entity_theme() {
- // Build a pattern in the form of "type1(\.|__)|type2(\.|__)|..." such that
- // all templates starting with an entity type or named like the entity type
+ // Build a pattern in the form of "(type1|type2|...)(\.|__)" such that all
+ // templates starting with an entity type or named like the entity type
// are found.
// This has to match the template suggestions provided in
// template_preprocess_entity().
$types = array_keys(entity_crud_get_info());
- $pattern = implode('(\.|__)|', $types) . '\.|__';
+ $pattern = '(' . implode('|', $types) . ')(\.|__)';
return array(
'entity_status' => array(