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