Inject session and purge services in PollService

This commit is contained in:
Liquidsoul 2019-04-19 10:12:32 +02:00 committed by Thomas Citharel
parent cd55e9a40a
commit 8f23917639
No known key found for this signature in database
GPG Key ID: A061B9DDE0CA0773
1 changed files with 4 additions and 3 deletions

View File

@ -53,11 +53,12 @@ class PollService {
*/
private $purgeService;
public function __construct(Connection $connect, LogService $logService, NotificationService $notificationService) {
public function __construct(Connection $connect, LogService $logService, NotificationService $notificationService, SessionService $sessionService, PurgeService $purgeService) {
$this->connect = $connect;
$this->logService = $logService;
$this->notificationService = $notificationService;
$this->sessionService = new SessionService();
$this->purgeService = new PurgeService($connect, $logService);
$this->sessionService = $sessionService;
$this->purgeService = $purgeService;
$this->pollRepository = RepositoryFactory::pollRepository();
$this->slotRepository = RepositoryFactory::slotRepository();
$this->voteRepository = RepositoryFactory::voteRepository();