From d73fe8eae0492086ff195a1ca5dfa07695757bae Mon Sep 17 00:00:00 2001 From: Angie Byron Date: Wed, 3 Jun 2009 02:50:21 +0000 Subject: #480044 by JohnAlbin: sites/all/ should take precedence over profiles when searching for modules and themes. --- includes/common.inc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'includes/common.inc') diff --git a/includes/common.inc b/includes/common.inc index a8a9a2466..299af56b8 100644 --- a/includes/common.inc +++ b/includes/common.inc @@ -3426,9 +3426,6 @@ function drupal_system_listing($mask, $directory, $key = 'name', $min_depth = 1) $searchdir = array($directory); $files = array(); - // Always search sites/all/* as well as the global directories - $searchdir[] = 'sites/all/' . $directory; - // The 'profiles' directory contains pristine collections of modules and // themes as organized by a distribution. It is pristine in the same way // that /modules is pristine for core; users should avoid changing anything @@ -3437,6 +3434,9 @@ function drupal_system_listing($mask, $directory, $key = 'name', $min_depth = 1) $searchdir[] = "profiles/$profile/$directory"; } + // Always search sites/all/* as well as the global directories + $searchdir[] = 'sites/all/' . $directory; + if (file_exists("$config/$directory")) { $searchdir[] = "$config/$directory"; } -- cgit v1.2.3