Some errors in the taxonomy feed caused by upload.module with the new changes to RSS support (categories,enclosures,etc):
warning: Invalid argument supplied for foreach() in /home/virtual/site440/fst/var/www/html/modules/upload.module on line 273.
warning: Invalid argument supplied for foreach() in /home/virtual/site440/fst/var/www/html/modules/upload.module on line 273.
warning: Cannot modify header information - headers already sent by (output started at /home/virtual/site440/fst/var/www/html/includes/common.inc:385) in /home/virtual/site440/fst/var/www/html/includes/common.inc on line 99.
That would be this part of upload.module:
case 'rss item':
$files = array();
foreach ($node->files as $file) {
if ($file->list) {
$files[] = $file;
}
}
Comments
Comment #1
Uwe Hermann commentedDoes this still happen with current HEAD? Can you provide more information about how to reproduce this? I wasn't able to.
Comment #2
Malthus commentedI have checked this also. I can't reproduce this bug. Also I have checked the current sources, the versions from February and several revisions in between. Am unable to locate any past code that could cause this result. (This code doesn't seem to have changed since February)
That error can only be occur if node->files exists and is not an array.
but the upload module adds the file element thusly:
(the node is loaded fully with node_load in node_feed)
Which makes it very unlikely that a non array $files is passed to case 'rss item' in nodeapi.
I started looking through the comtrib modules to see if another module tries to load $files to the $node object, but thats beyond me.