improves regexes parsing plugins metadata

git-svn-id: http://piwigo.org/svn/trunk@28969 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
mistic100 committed 2014-07-06 14:05:05 +00:00
1 parent dbedfd173f
commit 1633d8ffaa
4 files changed
+21 -19

No files matched your search

+1 -1
View File
@@ -380,7 +380,7 @@ function autoupdate_plugin(&$plugin)
$i++;
if ($i < 2) continue; // first lines are typically "<?php" and "/*"
if (preg_match('#Version: ([\\w.-]+)#', $line, $matches))
if (preg_match('/Version:\\s*([\\w.-]+)/', $line, $matches))
{
$fs_version = $matches[1];
}