Browse files

Cleanup based on review comments.

  • Loading branch information...
1 parent ea6ace4 commit 3a14f83a1c3753f01d6d0dbb6140df8eda6371fa @markstory markstory committed Jan 10, 2014
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/View/Input/Radio.php
View
4 src/View/Input/Radio.php
@@ -51,7 +51,7 @@ public function __construct($templates) {
* - `options` - An array of options. See below for more information.
* - `disabled` - Either true or an array of inputs to disable.
* When true, the select element will be disabled.
- * - `value` - A string of the option to mark as selected.
+ * - `value` - A string of the option to mark as selected.
* - `label` - Either false to disable label generation, or
* an array of attributes for all labels.
*
@@ -68,7 +68,6 @@ public function render($data) {
'label' => true,
'empty' => false,
];
- $opts = [];
$options = (array)$data['options'];
$escape = $data['escape'];
if (!empty($data['empty'])) {
@@ -77,6 +76,7 @@ public function render($data) {
}
unset($data['empty']);
+ $opts = [];
foreach ($options as $val => $text) {
if (is_int($val) && isset($text['text'], $text['value'])) {
$radio = $text;

0 comments on commit 3a14f83

Please sign in to comment.