|
From: <var...@us...> - 2014-12-08 17:29:40
|
Revision: 9436
http://sourceforge.net/p/phpwiki/code/9436
Author: vargenau
Date: 2014-12-08 17:29:32 +0000 (Mon, 08 Dec 2014)
Log Message:
-----------
Do not update page if already present in theme pgsrc
Modified Paths:
--------------
trunk/lib/upgrade.php
Modified: trunk/lib/upgrade.php
===================================================================
--- trunk/lib/upgrade.php 2014-12-08 17:28:47 UTC (rev 9435)
+++ trunk/lib/upgrade.php 2014-12-08 17:29:32 UTC (rev 9436)
@@ -163,6 +163,7 @@
$path = $WikiTheme->file("pgsrc");
// TBD: the call to fileSet prints a warning:
// Notice: Unable to open directory 'themes/MonoBook/pgsrc' for reading
+ $themepgsrc = array();
$pgsrc = new fileSet($path);
if ($pgsrc->getFiles()) {
echo "<h2>", sprintf(_("Check for necessary theme %s updates"),
@@ -171,6 +172,7 @@
if (substr($filename, -1, 1) == '~') continue;
if (substr($filename, -5, 5) == '.orig') continue;
$pagename = urldecode($filename);
+ $themepgsrc[] = $pagename;
$this->doPgsrcUpdate($pagename, $path, $filename);
}
}
@@ -198,7 +200,11 @@
if ($this->db_version < 1030.12200612) {
$this->_rename_to_help_page($pagename);
}
- $this->doPgsrcUpdate($pagename, $path, $filename);
+ if (in_array($pagename, $themepgsrc)) {
+ echo sprintf(_('%s already checked in theme pgsrc.'), $pagename).' '._('Skipped.').'<br />';
+ } else {
+ $this->doPgsrcUpdate($pagename, $path, $filename);
+ }
}
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|