function icon_bundle_disable in Icon API 7
Same name and namespace in other branches
- 8 icon.module \icon_bundle_disable()
Disable the icon bundle that matches {icon_bundle}.name in the database.
Parameters
array $bundle: The icon bundle array.
Return value
bool TRUE if successful, FALSE if the bundle is already disabled or on failure.
1 call to icon_bundle_disable()
- icon_bundle_overview_form_submit in includes/
admin.inc - Submit callback for 'icon_bundle_overview_form'.
File
- ./
icon.module, line 429 - icon.module Provides icon integration with menu items.
Code
function icon_bundle_disable(array $bundle = array()) {
$bundle['status'] = 0;
if (icon_bundle_save($bundle)) {
drupal_set_message(t('The icon bundle %bundle has been disabled.', array(
'%bundle' => $bundle['title'],
)));
icon_clear_all_caches();
return TRUE;
}
drupal_set_message(t('An error occurred while attemping to disable the icon bundle: %bundle.', array(
'%bundle' => $bundle['title'],
)), 'error');
return FALSE;
}