summaryrefslogtreecommitdiff
path: root/modules/field/field.attach.inc
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2009-04-26 09:18:20 +0000
committerDries Buytaert <dries@buytaert.net>2009-04-26 09:18:20 +0000
commit8e50687d8b69a07ddbacf65d6c7785a37bb41ab1 (patch)
tree913a07dd9459aae1fcad8a24e71afddfa417c43d /modules/field/field.attach.inc
parent1c076bc89f7a7374859e025c99f2eb5ea092188e (diff)
downloadbrdo-8e50687d8b69a07ddbacf65d6c7785a37bb41ab1.tar.gz
brdo-8e50687d8b69a07ddbacf65d6c7785a37bb41ab1.tar.bz2
- Patch #441180 by bjaspan, yched: field_attach_delete_bundle() called hook_field_attach_delete_bundle too soon.
Diffstat (limited to 'modules/field/field.attach.inc')
-rw-r--r--modules/field/field.attach.inc12
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/field/field.attach.inc b/modules/field/field.attach.inc
index 1a67b4754..acc541f83 100644
--- a/modules/field/field.attach.inc
+++ b/modules/field/field.attach.inc
@@ -729,17 +729,17 @@ function _field_attach_rename_bundle($bundle_old, $bundle_new) {
* The bundle to delete.
*/
function _field_attach_delete_bundle($bundle) {
- // Let other modules act on deleting the bundle
- foreach (module_implements('field_attach_delete_bundle') as $module) {
- $function = $module . '_field_attach_delete_bundle';
- $function($bundle);
- }
-
// Delete the instances themseves
$instances = field_info_instances($bundle);
foreach ($instances as $instance) {
field_delete_instance($instance['field_name'], $bundle);
}
+
+ // Let other modules act on deleting the bundle
+ foreach (module_implements('field_attach_delete_bundle') as $module) {
+ $function = $module . '_field_attach_delete_bundle';
+ $function($bundle, $instances);
+ }
}
/**