File "SiteDirectInstaller.php"

Full Path: /home/jlklyejr/public_html/wp-content-20241030122153/plugins/woocommerce/vendor/composer/installers/src/Composer/Installers/SiteDirectInstaller.php
File size: 654 bytes
MIME-type: text/x-php
Charset: utf-8

<?php

namespace Composer\Installers;

class SiteDirectInstaller extends BaseInstaller
{
    protected $locations = array(
        'module' => 'modules/{$vendor}/{$name}/',
        'plugin' => 'plugins/{$vendor}/{$name}/'
    );

    public function inflectPackageVars($vars)
    {
        return $this->parseVars($vars);
    }

    protected function parseVars($vars)
    {
        $vars['vendor'] = strtolower($vars['vendor']) == 'sitedirect' ? 'SiteDirect' : $vars['vendor'];
        $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
        $vars['name'] = str_replace(' ', '', ucwords($vars['name']));

        return $vars;
    }
}