From 2cd4de00ca0f646f12b906768736e2b37217d211 Mon Sep 17 00:00:00 2001 From: aB0t Date: Mon, 11 Mar 2024 16:56:07 +0200 Subject: [PATCH] Update on v1.2.0 (changes towards the next release) Here's an update on the current version, which includes changes towards the next release still in development. --- componentbuilderlanguagepackaging.xml | 2 +- script.php | 43 --------------------------- 2 files changed, 1 insertion(+), 44 deletions(-) diff --git a/componentbuilderlanguagepackaging.xml b/componentbuilderlanguagepackaging.xml index 14a4433..522808a 100644 --- a/componentbuilderlanguagepackaging.xml +++ b/componentbuilderlanguagepackaging.xml @@ -1,7 +1,7 @@ PLG_EXTENSION_COMPONENTBUILDERLANGUAGEPACKAGING - 10th March, 2024 + 11th March, 2024 Llewellyn van der Merwe joomla@vdm.io https://dev.vdm.io diff --git a/script.php b/script.php index f98dec4..026a8c9 100644 --- a/script.php +++ b/script.php @@ -48,49 +48,6 @@ class plgExtensionComponentbuilderLanguagePackagingInstallerScript if ('install' === $route) { -// needs fix - - - // check that componentbuilder is installed - $pathToCore = JPATH_ADMINISTRATOR . '/components/com_componentbuilder/helpers/componentbuilder.php'; - if (!JFile::exists($pathToCore)) - { - $app->enqueueMessage('Joomla Component Builder must first be installed from Joomla Component Builder.', 'error'); - return false; - } - - // load the helper class - JLoader::register('ComponentbuilderHelper', JPATH_ADMINISTRATOR . '/components/com_componentbuilder/helpers/componentbuilder.php'); - - // block install - $blockInstall = true; - - // check the version of JCB - $manifest = ComponentbuilderHelper::manifest(); - if (isset($manifest->version) && strpos($manifest->version, '.') !== false) - { - // get the version - $jcbVersion = explode('.', $manifest->version); - // check that we have JCB 3.0.0 or higher installed - if (count($jcbVersion) == 3 && $jcbVersion[0] >= 3 && - ( - ($jcbVersion[0] == 3 && $jcbVersion[1] == 0 && $jcbVersion[2] >= 0) || - ($jcbVersion[0] == 3 && $jcbVersion[1] > 0) || - $jcbVersion[0] > 3) - ) - { - $blockInstall = false; - } - } - - // allow install if all conditions are met - if ($blockInstall) - { - $app->enqueueMessage('Please upgrade to JCB v3.0.0 or higher before installing this plugin.', 'error'); - return false; - } - - // check that componentbuilder is installed $pathToCore = JPATH_ADMINISTRATOR . '/components/com_componentbuilder/helpers/componentbuilder.php'; if (!JFile::exists($pathToCore))