function _coder_review_is_drupal_core in Coder 7.2
Same name and namespace in other branches
- 7 coder_review/coder_review.module \_coder_review_is_drupal_core()
Determines if a module is part of Drupal's core group.
Parameters
object $system: ???
Return value
bool TRUE if a module is part of Drupal's core group; otherwise, FALSE.
1 call to _coder_review_is_drupal_core()
- _coder_review_settings_form in coder_review/
coder_review.module - Form constructor: Builds settings form API array for coder_review.
File
- coder_review/
coder_review.common.inc, line 1375 - Common functions used by both the drush and form interfaces.
Code
function _coder_review_is_drupal_core($system) {
$info_file = dirname(realpath($system->filename)) . '/' . $system->name . '.info';
$info = drupal_parse_info_file($info_file);
return !empty($info['package']) && strtolower($info['package']) == 'core';
}