mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-08 00:04:27 +02:00
Simplify AddonHelper::getAvailableAddons(), move style logic into Module class
This commit is contained in:
parent
af1894504d
commit
a80bf0ddf1
4 changed files with 30 additions and 8 deletions
|
@ -36,15 +36,21 @@ final class AddonProxy implements AddonHelper
|
|||
}
|
||||
|
||||
/**
|
||||
* Returns the list of available addons with their current status and info.
|
||||
* Returns the list of available addons.
|
||||
*
|
||||
* This list is made from scanning the addon/ folder.
|
||||
* Unsupported addons are excluded unless they already are enabled or system.show_unsupported_addon is set.
|
||||
*
|
||||
* @return array<array<string|string|array>>
|
||||
* @return string[]
|
||||
*/
|
||||
public function getAvailableAddons(): array
|
||||
{
|
||||
return Addon::getAvailableList();
|
||||
return array_map(
|
||||
function(array $item) {
|
||||
return $item[0];
|
||||
},
|
||||
Addon::getAvailableList()
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue