From 7282418baa20861dd8132524bc99be65ed9c1c24 Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Sat, 14 Jan 2017 16:43:32 +0100 Subject: Move user.css to data folder --- application/Updater.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'application') diff --git a/application/Updater.php b/application/Updater.php index 704ce7ab..eb03c6d3 100644 --- a/application/Updater.php +++ b/application/Updater.php @@ -308,6 +308,22 @@ class Updater return true; } + + /** + * Move the file to inc/user.css to data/user.css. + * + * Note: Due to hardcoded paths, it's not unit testable. But one line of code should be fine. + * + * @return bool true if the update is successful, false otherwise. + */ + public function updateMethodMoveUserCss() + { + if (! is_file('inc/user.css')) { + return true; + } + + return rename('inc/user.css', 'data/user.css'); + } } /** -- cgit v1.2.3