mirror of
https://github.com/flarum/framework.git
synced 2025-02-21 14:24:57 +08:00
Filter composer icon array to only valid values (#3080)
This commit is contained in:
parent
b92c8e9079
commit
babc1317c5
@ -283,6 +283,14 @@ class Extension implements Arrayable
|
||||
{
|
||||
$properties = $this->getIcon();
|
||||
|
||||
if (empty($properties)) {
|
||||
return '';
|
||||
}
|
||||
|
||||
$properties = array_filter($properties, function ($item) {
|
||||
return is_string($item);
|
||||
});
|
||||
|
||||
unset($properties['name']);
|
||||
|
||||
return implode(';', array_map(function (string $property, string $value) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user