function _system_sort_requirements

7.x system.module _system_sort_requirements($a, $b)
6.x system.module _system_sort_requirements($a, $b)

Helper function to sort requirements.

1 string reference to '_system_sort_requirements'
system_status in drupal-6.x/modules/system/system.admin.inc
Menu callback: displays the site status report. Can also be used as a pure check.

File

drupal-6.x/modules/system/system.module, line 1156
Configuration system that lets administrators modify the workings of the site.

Code

function _system_sort_requirements($a, $b) {
  if (!isset($a['weight'])) {
    if (!isset($b['weight'])) {
      return strcmp($a['title'], $b['title']);
    }
    return -$b['weight'];
  }
  return isset($b['weight']) ? $a['weight'] - $b['weight'] : $a['weight'];
}