InstalledVersions::getInstalledPackages()

Returns a list of all package names which are present, either by being installed, replaced or provided


Return Return

(string[])


Top ↑

Source Source

File: libraries/lifterlms-cli/vendor/composer/InstalledVersions.php

     * @psalm-return list<string>
     */
    public static function getInstalledPackages()
    {
        $packages = array();
        foreach (self::getInstalled() as $installed) {
            $packages[] = array_keys($installed['versions']);
        }

        if (1 === \count($packages)) {
            return $packages[0];
        }


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.