summaryrefslogtreecommitdiff
path: root/Vote.php
diff options
context:
space:
mode:
authorMartin Fischer <martin@push-f.com>2022-10-13 09:20:20 +0200
committerMartin Fischer <martin@push-f.com>2022-10-13 09:21:50 +0200
commitdcaff40b74840b55413cfb13b96d25f191cbda24 (patch)
tree0021e8e4050e7f0a83e68d3d8a9c03fe8a7c7d0b /Vote.php
parent56e25a05db769f4601d4125a5aff91e685e16543 (diff)
refactor: clarify what a code comment refers to
Diffstat (limited to 'Vote.php')
-rw-r--r--Vote.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/Vote.php b/Vote.php
index ffedcba..f1fd043 100644
--- a/Vote.php
+++ b/Vote.php
@@ -235,8 +235,12 @@ class VoteHooks {
->addHeaderHtml('<h3>' . wfMessage('vote-add-your-vote')->inLanguage($parser->getTargetLanguage()) . '</h3>')
->addFooterHtml('<script type="application/json" data-votes>'. json_encode($votes) . '</script>');
+ $html = $form->getHTML(false);
+
// dirty hack to work around https://phabricator.wikimedia.org/T319216
- return str_replace('type="radio"', 'type="radio" required', $form->getHTML(false));
+ $html = str_replace('type="radio"', 'type="radio" required', $html);
+
+ return $html;
}
}