/** * Fixes database problems. * * @return void */ public function fix() { if (!($changeSet = $this->getItems())) { return false; } $changeSet->fix(); $this->fixSchemaVersion($changeSet); $this->fixUpdateVersion(); $installer = new JoomlaInstallerScript(); $installer->deleteUnexistingFiles(); $this->fixDefaultTextFilters(); /* * Finally, if the schema updates succeeded, make sure the database is * converted to utf8mb4 or, if not suported by the server, compatible to it. */ $statusArray = $changeSet->getStatus(); if (count($statusArray['error']) == 0) { $installer->convertTablesToUtf8mb4(false); } }