From f63d884cfe262cf6b5e402307d7aacb21d830718 Mon Sep 17 00:00:00 2001 From: Ian <aristophian@googlemail.com> Date: Sat, 5 Sep 2015 12:43:39 +0200 Subject: [PATCH] upgrader dead files and dirs Is there more? Please add! --- include/admin/upgrader.inc.php | 13 +++++++++---- include/functions_upgrader.inc.php | 10 ++++++++-- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/include/admin/upgrader.inc.php b/include/admin/upgrader.inc.php index 2a7e3d48..c6070f89 100644 --- a/include/admin/upgrader.inc.php +++ b/include/admin/upgrader.inc.php @@ -246,20 +246,25 @@ $tasks = array(array('version' => '0.5.1', array('version' => '2.0.2', 'function' => 'serendipity_removeDeadFiles_SPL', 'title' => 'Removal of obsolete and still resting files in 2.0', - 'arguments' => array(substr($serendipity['serendipityPath'], 0, -1), $dead_files_rest, array('internals'), true), - 'desc' => 'The following old dead files will additionally be removed from your system.<br><pre>' . implode(', ', $dead_files_rest) . '</pre>'), + 'arguments' => array(substr($serendipity['serendipityPath'], 0, -1), $dead_files_200, array('internals'), true), + 'desc' => 'The following old dead files will be removed from your system.<br><pre>' . implode(', ', $dead_files_200) . '</pre>'), array('version' => '2.0.2', 'function' => 'recursive_directory_iterator', 'title' => 'Removal of obsolete and dead directories', - 'arguments' => array($dead_dirs_rest), - 'desc' => 'The following old dead directories will additionally be removed from your system.<br><pre>' . implode(', ', $dead_dirs_rest) . '</pre>'), + 'arguments' => array($dead_dirs_200), + 'desc' => 'The following old dead directories will be removed from your system.<br><pre>' . implode(', ', $dead_dirs_200) . '</pre>'), array('version' => '2.0.2', 'function' => 'serendipity_upgrader_rewriteFeedIcon', 'title' => 'Rewrite path of big feedicon', 'desc' => 'Rewrite path of the big feedicon to not include the template path, since that path is not automatically detected'), + array('version' => '2.1.0', + 'function' => 'serendipity_removeDeadFiles_SPL', + 'title' => 'Removal of old dead files in v.2.0.2', + 'arguments' => array(substr($serendipity['serendipityPath'], 0, -1), $dead_files_202, array('internals'), true), + 'desc' => 'The following old dead files will be removed from your system.<br><pre>' . implode(', ', $dead_files_202) . '</pre>'), ); diff --git a/include/functions_upgrader.inc.php b/include/functions_upgrader.inc.php index dcfcdb02..41d20908 100644 --- a/include/functions_upgrader.inc.php +++ b/include/functions_upgrader.inc.php @@ -156,7 +156,7 @@ $dead_htmlarea_dirs = array( ); /* A list of old Serendipity files which were not marked obsolet with 2.0.0 upgrade - now 2.0.2 */ -$dead_files_rest = array( +$dead_files_200 = array( 'serendipity_editor.js', 'serendipity_define.js.php', 'bundled-libs/dragdrop.js', @@ -181,13 +181,19 @@ $dead_files_rest = array( ); /* A list of old lib directories which were not marked obsolet with 2.0.0 upgrade - now 2.0.2 */ -$dead_dirs_rest = array( +$dead_dirs_200 = array( $serendipity['serendipityPath'] . 'htmlarea/plugins/ImageManage', $serendipity['serendipityPath'] . 'htmlarea/plugins', $serendipity['serendipityPath'] . 'bundled-libs/YahooUI/treeview', $serendipity['serendipityPath'] . 'bundled-libs/YahooUI' ); +/* A list of old or beta Serendipity files which were not marked obsolet with the 2.0.2 upgrade */ +$dead_files_202 = array( + 'templates/default/admin/media_showitem.tpl', + 'templates/2k11/admin/media_showitem.tpl' +); + /** * recursive directory call to purge files and directories *