Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 0 additions & 50 deletions administrator/components/com_admin/script.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,6 @@ public function update($installer)
// Informational log only
}

// Uninstall plugins before removing their files and folders
$this->uninstallEosPlugin();

// This needs to stay for 2.5 update compatibility
$this->deleteUnexistingFiles();
$this->updateManifestCaches();
Expand Down Expand Up @@ -204,53 +201,6 @@ protected function updateDatabaseMysql()
}
}

/**
* Uninstall the 3.10 EOS plugin
*
* @return void
*
* @since 4.0.0
*/
protected function uninstallEosPlugin()
{
$db = Factory::getDbo();

// Check if the plg_quickicon_eos310 plugin is present
$extensionId = $db->setQuery(
$db->getQuery(true)
->select('extension_id')
->from('#__extensions')
->where('name = ' . $db->quote('plg_quickicon_eos310'))
)->loadResult();

// Skip uninstalling if it doesn't exist
if (!$extensionId) {
return;
}

try {
$db->transactionStart();

// Unprotect the plugin so we can uninstall it
$db->setQuery(
$db->getQuery(true)
->update('#__extensions')
->set('protected = 0')
->where($db->quoteName('extension_id') . ' = ' . $extensionId)
)->execute();

// Uninstall the plugin
$installer = new Installer();
$installer->setDatabase($db);
$installer->uninstall('plugin', $extensionId);

$db->transactionCommit();
} catch (\Exception $e) {
$db->transactionRollback();
throw $e;
}
}

/**
* Update the manifest caches
*
Expand Down