Skip to content

Commit 577cb1f

Browse files
committed
[skip ci] Update compile_once signatures for type safety
Changed the compile_once method signatures in BaseHtml and HtmlTable to use nullable JsUtils and typed mixed for the view parameter, improving type safety and PHP 8+ compatibility.
1 parent 67ea594 commit 577cb1f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Ajax/common/html/BaseHtml.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ public function setBsComponent($bsComponent) {
191191
return $this;
192192
}
193193

194-
protected function compile_once(JsUtils $js = NULL, &$view = NULL) {
194+
protected function compile_once(?JsUtils $js = NULL, mixed &$view = NULL) {
195195
if (! $this->_compiled) {
196196
if (isset($js)) {
197197
$beforeCompile = $js->getParam("beforeCompileHtml");

Ajax/semantic/html/collections/table/HtmlTable.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@ public function compile(?JsUtils $js = NULL, mixed &$view = NULL) {
423423
return parent::compile($js, $view);
424424
}
425425

426-
protected function compile_once(JsUtils $js = NULL, &$view = NULL) {
426+
protected function compile_once(?JsUtils $js = NULL, mixed &$view = NULL) {
427427
parent::compile_once($js, $view);
428428
if ($this->propertyContains("class", "sortable")) {
429429
$this->addEvent("execute", "$('#" . $this->identifier . "').tablesort().data('tablesort').sort($('th.default-sort'));");

0 commit comments

Comments
 (0)