protected function setupInstallPaths()
{
$cname = (string) $this->getManifest()->attributes()->client;
if ($cname) {
$client = ApplicationHelper::getClientInfo($cname, true);
if ($client === false) {
throw new \RuntimeException(Text::sprintf('JLIB_INSTALLER_ABORT_TPL_INSTALL_UNKNOWN_CLIENT', $cname));
}
$basePath = $client->path;
$this->clientId = $client->id;
} else {
$basePath = JPATH_SITE;
$this->clientId = 0;
}
if (empty($this->element)) {
throw new \RuntimeException(Text::sprintf('JLIB_INSTALLER_ABORT_MOD_INSTALL_NOFILE', Text::_('JLIB_INSTALLER_' . strtoupper($this->route))));
}
$this->parent->setPath('extension_root', $basePath . '/templates/' . $this->element);
}