You are here

function hook_domain_warnings_alter in Domain Access 6.2

Same name and namespace in other branches
  1. 7.2 domain.api.php \hook_domain_warnings_alter()

Allows modules to remove form_ids from the list set by hook_domainwarnings().

Required by Domain Settings, whose code is shown below.

Parameters

&$forms: An array of form_ids, passed by reference.

1 function implements hook_domain_warnings_alter()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

domain_settings_domain_warnings_alter in domain_settings/domain_settings.module
Implement hook_domain_warnings_alter().
1 invocation of hook_domain_warnings_alter()
domain_warning_check in ./domain.module
Sets a message to the site admin.

File

./API.php, line 760
API documentation file.

Code

function hook_domain_warnings_alter(&$forms) {

  // Forms which Domain Settings handles and are set as warnings.
  $core_forms = array(
    'system_admin_theme_settings',
    'system_site_information_settings',
    'system_site_maintenance_settings',
    'menu_configure',
  );
  foreach ($core_forms as $form_id) {
    if (isset($forms[$form_id])) {
      unset($forms[$form_id]);
    }
  }
}