aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/ImportBundle/Import/AbstractImport.php
diff options
context:
space:
mode:
authorThomas Citharel <tcit@tcit.fr>2017-05-28 21:50:23 +0200
committerGitHub <noreply@github.com>2017-05-28 21:50:23 +0200
commitb788add08787863ac2a0e68ddaf4620da4b2b33c (patch)
tree520242e7454abd9e4562d250a5be46496d41b9a6 /src/Wallabag/ImportBundle/Import/AbstractImport.php
parent35941d57ee4d06ec3557d4b126d5f6fd263bcf3a (diff)
parentde8d2a9005321a935e52f4471f031f73bb240412 (diff)
downloadwallabag-b788add08787863ac2a0e68ddaf4620da4b2b33c.tar.gz
wallabag-b788add08787863ac2a0e68ddaf4620da4b2b33c.tar.zst
wallabag-b788add08787863ac2a0e68ddaf4620da4b2b33c.zip
Merge pull request #3153 from wallabag/content-proxy-refactor
Move Tags assigner to a separate file
Diffstat (limited to 'src/Wallabag/ImportBundle/Import/AbstractImport.php')
-rw-r--r--src/Wallabag/ImportBundle/Import/AbstractImport.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Wallabag/ImportBundle/Import/AbstractImport.php b/src/Wallabag/ImportBundle/Import/AbstractImport.php
index 1d4a6e27..a61388c0 100644
--- a/src/Wallabag/ImportBundle/Import/AbstractImport.php
+++ b/src/Wallabag/ImportBundle/Import/AbstractImport.php
@@ -8,6 +8,7 @@ use Doctrine\ORM\EntityManager;
8use Wallabag\CoreBundle\Helper\ContentProxy; 8use Wallabag\CoreBundle\Helper\ContentProxy;
9use Wallabag\CoreBundle\Entity\Entry; 9use Wallabag\CoreBundle\Entity\Entry;
10use Wallabag\CoreBundle\Entity\Tag; 10use Wallabag\CoreBundle\Entity\Tag;
11use Wallabag\CoreBundle\Helper\TagsAssigner;
11use Wallabag\UserBundle\Entity\User; 12use Wallabag\UserBundle\Entity\User;
12use OldSound\RabbitMqBundle\RabbitMq\ProducerInterface; 13use OldSound\RabbitMqBundle\RabbitMq\ProducerInterface;
13use Symfony\Component\EventDispatcher\EventDispatcherInterface; 14use Symfony\Component\EventDispatcher\EventDispatcherInterface;
@@ -18,6 +19,7 @@ abstract class AbstractImport implements ImportInterface
18 protected $em; 19 protected $em;
19 protected $logger; 20 protected $logger;
20 protected $contentProxy; 21 protected $contentProxy;
22 protected $tagsAssigner;
21 protected $eventDispatcher; 23 protected $eventDispatcher;
22 protected $producer; 24 protected $producer;
23 protected $user; 25 protected $user;
@@ -26,11 +28,12 @@ abstract class AbstractImport implements ImportInterface
26 protected $importedEntries = 0; 28 protected $importedEntries = 0;
27 protected $queuedEntries = 0; 29 protected $queuedEntries = 0;
28 30
29 public function __construct(EntityManager $em, ContentProxy $contentProxy, EventDispatcherInterface $eventDispatcher) 31 public function __construct(EntityManager $em, ContentProxy $contentProxy, TagsAssigner $tagsAssigner, EventDispatcherInterface $eventDispatcher)
30 { 32 {
31 $this->em = $em; 33 $this->em = $em;
32 $this->logger = new NullLogger(); 34 $this->logger = new NullLogger();
33 $this->contentProxy = $contentProxy; 35 $this->contentProxy = $contentProxy;
36 $this->tagsAssigner = $tagsAssigner;
34 $this->eventDispatcher = $eventDispatcher; 37 $this->eventDispatcher = $eventDispatcher;
35 } 38 }
36 39