Hi,
I've been using multiblock on Drupal sites for many years and have always found it to be very useful.
Recently I came across an issue on a site when there were some multiblock instances created from a block provided by a module that was then disabled, this module currently doesn't check whether the original module still exists and can cause PHP warnings.
Here's a patch that deletes entries from the multiblock table for modules that are uninstalled - via hook_modules_uninstalled() - and adds a check to multiblock_get_block() to ensure the original module is enabled. Finally multiblock_call_block() calls multiblock_get_block($delta) and checks the data is returned rather than loading the data directly from the multiblock table.
This means that all multiblock instances of an uninstalled module will be deleted whereas one's for a disabled module will disappear from the blocks admin page but will reappear if the module is re-enabled at a later date.
Cheers,
Alan.
| Comment | File | Size | Author |
|---|---|---|---|
| multiblock_orig_modules_disabled_uninstalled.patch | 2.49 KB | altcom_alan |
Comments
Comment #3
intrafusionThanks for you help, this has been added into the module