public function PiwikInstaller::inflectPackageVars in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/composer/installers/src/Composer/Installers/PiwikInstaller.php \Composer\Installers\PiwikInstaller::inflectPackageVars()
Format package name to CamelCase
Parameters
array $vars:
Return value
array
Overrides BaseInstaller::inflectPackageVars
File
- vendor/
composer/ installers/ src/ Composer/ Installers/ PiwikInstaller.php, line 24
Class
- PiwikInstaller
- Class PiwikInstaller
Namespace
Composer\InstallersCode
public function inflectPackageVars($vars) {
$vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
$vars['name'] = str_replace(array(
'-',
'_',
), ' ', $vars['name']);
$vars['name'] = str_replace(' ', '', ucwords($vars['name']));
return $vars;
}