aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Entity
diff options
context:
space:
mode:
Diffstat (limited to 'src/Wallabag/CoreBundle/Entity')
-rw-r--r--src/Wallabag/CoreBundle/Entity/Entry.php4
-rw-r--r--src/Wallabag/CoreBundle/Entity/Tag.php5
2 files changed, 7 insertions, 2 deletions
diff --git a/src/Wallabag/CoreBundle/Entity/Entry.php b/src/Wallabag/CoreBundle/Entity/Entry.php
index 7d2d2027..f88d189d 100644
--- a/src/Wallabag/CoreBundle/Entity/Entry.php
+++ b/src/Wallabag/CoreBundle/Entity/Entry.php
@@ -7,7 +7,7 @@ use Doctrine\ORM\Mapping as ORM;
7use Symfony\Component\Validator\Constraints as Assert; 7use Symfony\Component\Validator\Constraints as Assert;
8use Hateoas\Configuration\Annotation as Hateoas; 8use Hateoas\Configuration\Annotation as Hateoas;
9use JMS\Serializer\Annotation\XmlRoot; 9use JMS\Serializer\Annotation\XmlRoot;
10use Wallabag\CoreBundle\Helper\Tools; 10use Wallabag\CoreBundle\Tools\Utils;
11 11
12/** 12/**
13 * Entry. 13 * Entry.
@@ -265,7 +265,7 @@ class Entry
265 public function setContent($content) 265 public function setContent($content)
266 { 266 {
267 $this->content = $content; 267 $this->content = $content;
268 $this->readingTime = Tools::getReadingTime($content); 268 $this->readingTime = Utils::getReadingTime($content);
269 $this->domainName = parse_url($this->url, PHP_URL_HOST); 269 $this->domainName = parse_url($this->url, PHP_URL_HOST);
270 270
271 return $this; 271 return $this;
diff --git a/src/Wallabag/CoreBundle/Entity/Tag.php b/src/Wallabag/CoreBundle/Entity/Tag.php
index 6f005314..97c4579f 100644
--- a/src/Wallabag/CoreBundle/Entity/Tag.php
+++ b/src/Wallabag/CoreBundle/Entity/Tag.php
@@ -96,6 +96,11 @@ class Tag
96 $this->entries[] = $entry; 96 $this->entries[] = $entry;
97 } 97 }
98 98
99 public function hasEntry($entry)
100 {
101 return $this->entries->contains($entry);
102 }
103
99 /** 104 /**
100 * @return User 105 * @return User
101 */ 106 */