diff options
author | Morris Jobke <hey@morrisjobke.de> | 2017-11-24 10:41:51 +0100 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2017-11-25 12:01:02 +0100 |
commit | df61d43529418aace241b99be106ff9a35188dac (patch) | |
tree | 1dee18bbed4828e67b96f87c41f3a43f799fd822 /apps/updatenotification/lib | |
parent | 0e2f00ec59424b2ef5708a928856e2c75abe6deb (diff) | |
download | nextcloud-server-df61d43529418aace241b99be106ff9a35188dac.tar.gz nextcloud-server-df61d43529418aace241b99be106ff9a35188dac.zip |
Make isUpdateAvailable non-static
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'apps/updatenotification/lib')
-rw-r--r-- | apps/updatenotification/lib/Notification/BackgroundJob.php | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/apps/updatenotification/lib/Notification/BackgroundJob.php b/apps/updatenotification/lib/Notification/BackgroundJob.php index 08baa35664f..3c0cac60cde 100644 --- a/apps/updatenotification/lib/Notification/BackgroundJob.php +++ b/apps/updatenotification/lib/Notification/BackgroundJob.php @@ -53,6 +53,9 @@ class BackgroundJob extends TimedJob { /** @var IClientService */ protected $client; + /** @var Installer */ + protected $installer; + /** @var string[] */ protected $users; @@ -64,8 +67,9 @@ class BackgroundJob extends TimedJob { * @param IGroupManager $groupManager * @param IAppManager $appManager * @param IClientService $client + * @param Installer $installer */ - public function __construct(IConfig $config, IManager $notificationManager, IGroupManager $groupManager, IAppManager $appManager, IClientService $client) { + public function __construct(IConfig $config, IManager $notificationManager, IGroupManager $groupManager, IAppManager $appManager, IClientService $client, Installer $installer) { // Run once a day $this->setInterval(60 * 60 * 24); @@ -74,6 +78,7 @@ class BackgroundJob extends TimedJob { $this->groupManager = $groupManager; $this->appManager = $appManager; $this->client = $client; + $this->installer = $installer; } protected function run($argument) { @@ -257,6 +262,6 @@ class BackgroundJob extends TimedJob { * @return string|false */ protected function isUpdateAvailable($app) { - return Installer::isUpdateAvailable($app, \OC::$server->getAppFetcher()); + return $this->installer->isUpdateAvailable($app); } } |