Back to PackageAdapter class

Method setupInstallPaths

protected void
setupInstallPaths
()
Method to do any prechecks and setup the install paths for the extension
Returns
  • void
Since
  • 3.4
-
  • \RuntimeException

Method setupInstallPaths - Source code

/**
 * Method to do any prechecks and setup the install paths for the extension
 *
 * @return  void
 *
 * @since   3.4
 * @throws  \RuntimeException
 */
protected function setupInstallPaths()
{
    $packagepath = (string) $this->getManifest()->packagename;
    if (empty($packagepath)) {
        throw new \RuntimeException(Text::sprintf('JLIB_INSTALLER_ABORT_PACK_INSTALL_NO_PACK', Text::_('JLIB_INSTALLER_' . strtoupper($this->route))));
    }
    $this->parent->setPath('extension_root', JPATH_MANIFESTS . '/packages/' . $packagepath);
}