~davidstrauss/drupal/195416-per-connection-prefixes

« back to all changes in this revision

Viewing changes to modules/system/system.module

  • Committer: dries
  • Date: 2006-08-08 21:18:02 UTC
  • Revision ID: vcs-imports@canonical.com-20060808211802-727a83b3dc21261b
- Patch #77549 by adrian: install profiles should be in their own directory.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
<?php
2
 
// $Id: system.module,v 1.338 2006/08/07 19:35:41 dries Exp $
 
2
// $Id: system.module,v 1.339 2006/08/08 21:18:04 dries Exp $
3
3
 
4
4
/**
5
5
 * @file
954
954
 */
955
955
function system_listing($mask, $directory, $key = 'name', $min_depth = 1) {
956
956
  $config = conf_path();
 
957
  $profile = variable_get('install_profile', 'default');
957
958
  $searchdir = array($directory);
958
959
  $files = array();
959
960
 
960
961
  // Always search sites/all/* as well as the global directories
961
962
  $searchdir[] = 'sites/all';
 
963
 
 
964
  if (file_exists("profiles/$profile/$directory")) {
 
965
    $searchdir[] = "profiles/$profile/$directory";
 
966
  }
 
967
 
962
968
  if (file_exists("$config/$directory")) {
963
969
    $searchdir[] = "$config/$directory";
964
970
  }