diff options
author | Victor Dubiniuk <victor.dubiniuk@gmail.com> | 2015-09-15 21:11:52 +0300 |
---|---|---|
committer | Victor Dubiniuk <victor.dubiniuk@gmail.com> | 2015-09-15 21:12:49 +0300 |
commit | 1f7ac2c309b7a43746a65f4676373071a8c3b359 (patch) | |
tree | 8f29dba4430e0029d02429d26ccb5bfb924c6a28 /apps/files_versions/lib | |
parent | 0cefbd76b9369135075fda8c210dfa9ff88a264c (diff) | |
download | nextcloud-server-1f7ac2c309b7a43746a65f4676373071a8c3b359.tar.gz nextcloud-server-1f7ac2c309b7a43746a65f4676373071a8c3b359.zip |
Postrebase cleanup
Diffstat (limited to 'apps/files_versions/lib')
-rw-r--r-- | apps/files_versions/lib/backgroundjob/expireversions.php | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/apps/files_versions/lib/backgroundjob/expireversions.php b/apps/files_versions/lib/backgroundjob/expireversions.php index 8aa1fcb0635..ec5612b5a67 100644 --- a/apps/files_versions/lib/backgroundjob/expireversions.php +++ b/apps/files_versions/lib/backgroundjob/expireversions.php @@ -21,7 +21,6 @@ namespace OCA\Files_Versions\BackgroundJob; -use OCP\IDBConnection; use OCP\IUserManager; use OCA\Files_Versions\AppInfo\Application; use OCA\Files_Versions\Storage; @@ -35,25 +34,19 @@ class ExpireVersions extends \OC\BackgroundJob\TimedJob { * @var Expiration */ private $expiration; - - /** - * @var IDBConnection - */ - private $dbConnection; /** * @var IUserManager */ private $userManager; - public function __construct(IDBConnection $dbConnection = null, IUserManager $userManager = null, Expiration $expiration = null) { + public function __construct(IUserManager $userManager = null, Expiration $expiration = null) { // Run once per 30 minutes $this->setInterval(60 * 30); - if (is_null($expiration) || is_null($userManager) || is_null($dbConnection)) { + if (is_null($expiration) || is_null($userManager)) { $this->fixDIForJobs(); } else { - $this->dbConnection = $dbConnection; $this->expiration = $expiration; $this->userManager = $userManager; } @@ -61,7 +54,6 @@ class ExpireVersions extends \OC\BackgroundJob\TimedJob { protected function fixDIForJobs() { $application = new Application(); - $this->dbConnection = \OC::$server->getDatabaseConnection(); $this->expiration = $application->getContainer()->query('Expiration'); $this->userManager = \OC::$server->getUserManager(); } @@ -103,4 +95,4 @@ class ExpireVersions extends \OC\BackgroundJob\TimedJob { return true; } -}
\ No newline at end of file +} |