Commit f7ae7fa3 authored by drumm's avatar drumm

#81843 by asimmonds. Check to make sure hook_requirements() is implemented before executing it.

parent b5ba248e
...@@ -631,7 +631,9 @@ function drupal_check_profile($profile) { ...@@ -631,7 +631,9 @@ function drupal_check_profile($profile) {
$requirements = array(); $requirements = array();
foreach ($installs as $install) { foreach ($installs as $install) {
require_once $install->filename; require_once $install->filename;
$requirements = array_merge($requirements, module_invoke($install->name, 'requirements', 'install')); if (module_hook($install->name, 'requirements')) {
$requirements = array_merge($requirements, module_invoke($install->name, 'requirements', 'install'));
}
} }
return $requirements; return $requirements;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment