|
40 | 40 | class BackgroundJob extends TimedJob { |
41 | 41 | protected $connectionNotifications = [3, 7, 14, 30]; |
42 | 42 |
|
43 | | - /** @var IConfig */ |
44 | | - protected $config; |
45 | | - |
46 | | - /** @var IManager */ |
47 | | - protected $notificationManager; |
48 | | - |
49 | | - /** @var IGroupManager */ |
50 | | - protected $groupManager; |
51 | | - |
52 | | - /** @var IAppManager */ |
53 | | - protected $appManager; |
54 | | - |
55 | | - /** @var IClientService */ |
56 | | - protected $client; |
57 | | - |
58 | | - /** @var Installer */ |
59 | | - protected $installer; |
60 | | - |
61 | 43 | /** @var string[] */ |
62 | 44 | protected $users; |
63 | 45 |
|
64 | | - public function __construct(ITimeFactory $timeFactory, |
65 | | - IConfig $config, |
66 | | - IManager $notificationManager, |
67 | | - IGroupManager $groupManager, |
68 | | - IAppManager $appManager, |
69 | | - IClientService $client, |
70 | | - Installer $installer) { |
| 46 | + public function __construct( |
| 47 | + ITimeFactory $timeFactory, |
| 48 | + protected IConfig $config, |
| 49 | + protected IManager $notificationManager, |
| 50 | + protected IUserManager $userManager, |
| 51 | + protected IGroupManager $groupManager, |
| 52 | + protected IAppManager $appManager, |
| 53 | + protected IClientService $client, |
| 54 | + protected Installer $installer |
| 55 | + ) { |
71 | 56 | parent::__construct($timeFactory); |
72 | 57 | // Run once a day |
73 | 58 | $this->setInterval(60 * 60 * 24); |
74 | | - |
75 | | - $this->config = $config; |
76 | | - $this->notificationManager = $notificationManager; |
77 | | - $this->groupManager = $groupManager; |
78 | | - $this->appManager = $appManager; |
79 | | - $this->client = $client; |
80 | | - $this->installer = $installer; |
81 | 59 | } |
82 | 60 |
|
83 | 61 | protected function run($argument) { |
@@ -264,7 +242,8 @@ protected function deleteOutdatedNotifications($app, $version) { |
264 | 242 | protected function createVersionCheck(): VersionCheck { |
265 | 243 | return new VersionCheck( |
266 | 244 | $this->client, |
267 | | - $this->config |
| 245 | + $this->config, |
| 246 | + $this->userManager, |
268 | 247 | ); |
269 | 248 | } |
270 | 249 |
|
|
0 commit comments