This patch keep nodequeue from spouting errors when there are no queues yet. To reproduce, install nodequeue fresh then go to admin/content/nodequeue. This only is visible in PHP5 or installations where warnings are enabled.

CommentFileSizeAuthor
nodequeue_foreach_warnings.patch545 bytesquicksketch

Comments

merlinofchaos’s picture

Status: Needs review » Fixed

http://drupal.org/cvs?commit=77351

Whoops. Forgot to credit you in the commit message. Sorry about that. I try to!

cog.rusty’s picture

Version: 7.x-2.x-dev » 5.x-2.0-beta
Category: task » bug
Status: Fixed » Active

Is this fixed? In 5.x-2.0-beta (which does contain the $qids=array(); fix), with PHP 5.2.1, no queues defined yet, I am getting

warning: Invalid argument supplied for foreach() in ...... nodequeue.views.inc on line 75.
warning: Invalid argument supplied for foreach() in ...... nodequeue.views.inc on line 160.

merlinofchaos’s picture

Status: Active » Fixed

The fix for the second part of this was something I had, but apparently hadn't checked in.

Anonymous’s picture

Status: Fixed » Closed (fixed)