diff options
author | mistic100 <mistic@piwigo.org> | 2012-06-29 14:31:29 +0000 |
---|---|---|
committer | mistic100 <mistic@piwigo.org> | 2012-06-29 14:31:29 +0000 |
commit | aa10f5455869fc782b6cd3bef331b3cfbeb85f5f (patch) | |
tree | 256d5598a67313553a687455a18e52dec6c0da22 | |
parent | f3c84114ef7310aa7b5d3e52ed56497b3c1726da (diff) |
merge r16177 from trunk
incompatible plugins check doesn't work since 2.4, because version number format has changed
git-svn-id: http://piwigo.org/svn/branches/2.4@16178 68402e56-0260-453c-a942-63ccdbb3a9ee
-rw-r--r-- | admin/include/plugins.class.php | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/admin/include/plugins.class.php b/admin/include/plugins.class.php index 654b17b47..65e22b7b1 100644 --- a/admin/include/plugins.class.php +++ b/admin/include/plugins.class.php @@ -275,7 +275,16 @@ DELETE FROM ' . PLUGINS_TABLE . ' WHERE id=\'' . $plugin_id . '\''; { $version = $pem_versions[0]['name']; } - $branch = substr($version, 0, strrpos($version, '.')); + + if (substr_count($version, '.') > 1) + { + $branch = substr($version, 0, strrpos($version, '.')); + } + else + { + $branch = $version; + } + foreach ($pem_versions as $pem_version) { if (strpos($pem_version['name'], $branch) === 0) |