Bolt\Composer\PackageManager::setup PHP Метод

setup() приватный Метод

- Copy/update the installer event class - Update the composer.json - Test connection to the server
private setup ( )
    private function setup()
    {
        if ($this->started) {
            return;
        }
        if ($this->app['extend.writeable']) {
            // Do required JSON update/set up
            try {
                $this->updateJson();
            } catch (ParseException $e) {
                $this->app['logger.flash']->danger(Trans::__('Error reading extensions/composer.json file: %ERROR%', ['%ERROR%' => $e->getMessage()]));
                $this->started = false;
                return;
            }
            // Ping the extensions server to confirm connection
            $this->ping(true);
        }
        $this->started = true;
    }