diff options
Diffstat (limited to 'lib/Utility/Updater.php')
-rw-r--r-- | lib/Utility/Updater.php | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/lib/Utility/Updater.php b/lib/Utility/Updater.php index 7a7f11e92..5f9edbeda 100644 --- a/lib/Utility/Updater.php +++ b/lib/Utility/Updater.php @@ -5,10 +5,10 @@ * This file is licensed under the Affero General Public License version 3 or * later. See the COPYING file. * - * @author Alessandro Cosentino <cosenal@gmail.com> - * @author Bernhard Posselt <dev@bernhard-posselt.com> - * @copyright Alessandro Cosentino 2012 - * @copyright Bernhard Posselt 2012, 2014 + * @author Alessandro Cosentino <cosenal@gmail.com> + * @author Bernhard Posselt <dev@bernhard-posselt.com> + * @copyright 2012 Alessandro Cosentino + * @copyright 2012-2014 Bernhard Posselt */ @@ -19,7 +19,8 @@ use \OCA\News\Service\FeedService; use \OCA\News\Service\ItemService; -class Updater { +class Updater +{ private $folderService; @@ -27,26 +28,30 @@ class Updater { private $itemService; public function __construct(FolderService $folderService, - FeedService $feedService, - ItemService $itemService) { + FeedService $feedService, + ItemService $itemService + ) { $this->folderService = $folderService; $this->feedService = $feedService; $this->itemService = $itemService; } - public function beforeUpdate() { + public function beforeUpdate() + { $this->folderService->purgeDeleted(); $this->feedService->purgeDeleted(); } - public function update() { + public function update() + { $this->feedService->updateAll(); } - public function afterUpdate() { + public function afterUpdate() + { $this->itemService->autoPurgeOld(); } |