diff --git a/modules/poll.module b/modules/poll.module index 0313b62c8ffbaa3bb3183bc3eb729030fedef1f2..a2e8027607e4913d3917d308fd1ac7e51a43f571 100644 --- a/modules/poll.module +++ b/modules/poll.module @@ -369,7 +369,7 @@ function poll_update($node) { db_query("UPDATE poll SET runtime = %d, active = %d WHERE nid = %d", $node->runtime, $node->active, $node->nid); db_query("DELETE FROM poll_choices WHERE nid = %d", $node->nid); - for ($i = 0; $i < $node->choices; $i++) { + for ($i = 0; $i < count($node->choice); $i++) { $choice->chtext = $node->choice[$i]; $choice->chvotes = (int)$node->chvotes[$i]; $choice->chorder = $i;