mirror of
https://github.com/friendica/friendica
synced 2025-02-22 02:46:48 +00:00
Move getVisibleList() into AddonHelper
This commit is contained in:
parent
5504fdcd06
commit
c4469cb624
3 changed files with 22 additions and 3 deletions
|
@ -300,6 +300,8 @@ class Addon
|
||||||
/**
|
/**
|
||||||
* Returns the list of non-hidden enabled addon names
|
* Returns the list of non-hidden enabled addon names
|
||||||
*
|
*
|
||||||
|
* @deprecated 2025.02 Use `Friendica\Core\Addon\AddonHelper::getVisibleList()` instead
|
||||||
|
*
|
||||||
* @return array
|
* @return array
|
||||||
* @throws \Exception
|
* @throws \Exception
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -20,9 +20,16 @@ interface AddonHelper
|
||||||
public function isEnabled(string $addonId): bool;
|
public function isEnabled(string $addonId): bool;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a list of the enabled addon names
|
* Returns a list with the IDs of the enabled addons
|
||||||
*
|
*
|
||||||
* @return array
|
* @return string[]
|
||||||
*/
|
*/
|
||||||
public function getEnabledList(): array;
|
public function getEnabledList(): array;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the list of the IDs of the non-hidden enabled addons
|
||||||
|
*
|
||||||
|
* @return string[]
|
||||||
|
*/
|
||||||
|
public static function getVisibleList(): array;
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,7 +27,7 @@ final class AddonProxy implements AddonHelper
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a list of the enabled addon names
|
* Returns a list with the IDs of the enabled addons
|
||||||
*
|
*
|
||||||
* @return string[]
|
* @return string[]
|
||||||
*/
|
*/
|
||||||
|
@ -35,4 +35,14 @@ final class AddonProxy implements AddonHelper
|
||||||
{
|
{
|
||||||
return Addon::getEnabledList();
|
return Addon::getEnabledList();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the list of the IDs of the non-hidden enabled addons
|
||||||
|
*
|
||||||
|
* @return string[]
|
||||||
|
*/
|
||||||
|
public static function getVisibleList(): array
|
||||||
|
{
|
||||||
|
return Addon::getVisibleList();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue