mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
fix(ocp): Deprecate getInstalledApps and replace with clearer method name
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
parent
d2864f7d84
commit
fb917c495b
2 changed files with 21 additions and 3 deletions
|
|
@ -149,11 +149,20 @@ class AppManager implements IAppManager {
|
|||
}
|
||||
|
||||
/**
|
||||
* List all installed apps
|
||||
* Deprecated alias
|
||||
*
|
||||
* @return string[]
|
||||
*/
|
||||
public function getInstalledApps() {
|
||||
return $this->getEnabledApps();
|
||||
}
|
||||
|
||||
/**
|
||||
* List all enabled apps, either for everyone or for some groups
|
||||
*
|
||||
* @return list<string>
|
||||
*/
|
||||
public function getEnabledApps(): array {
|
||||
return array_keys($this->getInstalledAppsValues());
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -79,14 +79,14 @@ interface IAppManager {
|
|||
* @param string $appId
|
||||
* @return bool
|
||||
* @since 8.0.0
|
||||
* @deprecated 31.0.0 Use either {@see self::isEnabledForUser} or {@see self::isEnabledForAnyone}
|
||||
* @deprecated 32.0.0 Use either {@see self::isEnabledForUser} or {@see self::isEnabledForAnyone}
|
||||
*/
|
||||
public function isInstalled($appId);
|
||||
|
||||
/**
|
||||
* Check if an app is enabled in the instance, either for everyone or for specific groups
|
||||
*
|
||||
* @since 31.0.0
|
||||
* @since 32.0.0
|
||||
*/
|
||||
public function isEnabledForAnyone(string $appId): bool;
|
||||
|
||||
|
|
@ -186,9 +186,18 @@ interface IAppManager {
|
|||
*
|
||||
* @return string[]
|
||||
* @since 8.1.0
|
||||
* @deprecated 32.0.0 Use either {@see self::getEnabledApps} or {@see self::getEnabledAppsForUser}
|
||||
*/
|
||||
public function getInstalledApps();
|
||||
|
||||
/**
|
||||
* List all apps enabled, either for everyone or for specific groups only
|
||||
*
|
||||
* @return list<string>
|
||||
* @since 32.0.0
|
||||
*/
|
||||
public function getEnabledApps(): array;
|
||||
|
||||
/**
|
||||
* Clear the cached list of apps when enabling/disabling an app
|
||||
* @since 8.1.0
|
||||
|
|
|
|||
Loading…
Reference in a new issue