mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-02 01:52:10 +09:00
Fix unnecessary use of count() in addon.admin.model.php
https://xetown.com/questions/1831837
This commit is contained in:
parent
cec183d59e
commit
6dbfde8de1
1 changed files with 3 additions and 3 deletions
|
|
@ -398,10 +398,10 @@ class addonAdminModel extends addon
|
|||
}
|
||||
|
||||
$obj->options = array();
|
||||
for($i = 0, $c = count($val->options); $i < $c; $i++)
|
||||
foreach ($val->options ?? [] as $i => $option)
|
||||
{
|
||||
$obj->options[$i]->title = $val->options[$i]->title->body;
|
||||
$obj->options[$i]->value = $val->options[$i]->value->body;
|
||||
$obj->options[$i]->title = $option->title->body;
|
||||
$obj->options[$i]->value = $option->value->body;
|
||||
}
|
||||
$addon_info->extra_vars[] = $obj;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue