Closed (fixed)
Project:
Boost
Version:
6.x-1.0-beta1
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
4 Jun 2009 at 06:45 UTC
Updated:
29 Jun 2009 at 17:30 UTC
In boost_cache_expire_derivative(), the following code:
#path redirects
if (module_exists('path_redirect')){
$path_redirects = boost_path_redirect_load(array('redirect' => $path));
}
#flush caches
boost_cache_expire($path_alias, $wildcard);
foreach($path_redirects as $path_redirect) {
boost_cache_expire($path_redirect['path'], $wildcard );
}
Results in "warning: Invalid argument supplied for foreach() in /www/beta4/httpdocs/sites/all/modules/boost/boost.module on line 513"
if the path_redirect module is not installed.
To fix, initialize $path_redirects to an empty array or wrap the foreach in an "if (isset(..."
See patch for latter solution.
| Comment | File | Size | Author |
|---|---|---|---|
| boost.invalidargument.patch | 551 bytes | setvik |
Comments
Comment #1
mikeytown2 commentedTested & looks good. Thanks for supplying the patch!
Comment #2
mikeytown2 commentedcommitted
Comment #3
asb commentedHi,
confirming the issue in Drupal 6.12 with 6.x-1.0-beta1. The patch applies cleanly and works as advertised.
Thanks & greetings, -asb