[2.5.x] Fixing version comparison for database schema #3250

wants to merge 2 commits into


None yet

1 participant

Hackwar commented Mar 6, 2014

#2147 tried to fix a broken version comparison that was there, but did it in a wrong way. The schema was compared against the Joomla version, although the two have actually very little in common.

$this->schemaVersion is the schema version stored in the database. $this->changeset->getSchema() is the latest available file in the respective folder of com_admin. Those 2 should be compared and not $this->schemaVersion with the Joomla version.

Since before #2147 it only compared the first 5 characters of the schemaVersion and the Joomla version, the check was always positive for all Joomla 2.5.1x versions and it only wanted to update for new Joomla 3.x.x versions, but didn't really react during development time. Introducing the version comparison showed that bug, but didn't really fix it. This PR should do that.

Mea culpa.

@Hackwar Hackwar closed this Mar 6, 2014
@Hackwar Hackwar deleted the Hackwar:patch-13 branch Jan 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment