Code Duplication    Length = 7-7 lines in 2 locations

Sources/Display.php 1 location

@@ 644-650 (lines=7) @@
641
		$pollOptions = array();
642
		$realtotal = 0;
643
		$pollinfo['has_voted'] = false;
644
		while ($row = $smcFunc['db_fetch_assoc']($request))
645
		{
646
			censorText($row['label']);
647
			$pollOptions[$row['id_choice']] = $row;
648
			$realtotal += $row['votes'];
649
			$pollinfo['has_voted'] |= $row['voted_this'] != -1;
650
		}
651
		$smcFunc['db_free_result']($request);
652
653
		// If this is a guest we need to do our best to work out if they have voted, and what they voted for.

Sources/Printpage.php 1 location

@@ 117-123 (lines=7) @@
114
		$pollOptions = array();
115
		$realtotal = 0;
116
		$pollinfo['has_voted'] = false;
117
		while ($row = $smcFunc['db_fetch_assoc']($request))
118
		{
119
			censorText($row['label']);
120
			$pollOptions[$row['id_choice']] = $row;
121
			$realtotal += $row['votes'];
122
			$pollinfo['has_voted'] |= $row['voted_this'] != -1;
123
		}
124
		$smcFunc['db_free_result']($request);
125
126
		// If this is a guest we need to do our best to work out if they have voted, and what they voted for.