diff --git a/src/Bundle/ChillPersonBundle/Entity/AccompanyingPeriod/Comment.php b/src/Bundle/ChillPersonBundle/Entity/AccompanyingPeriod/Comment.php index 75d1b2857..7be0eccd1 100644 --- a/src/Bundle/ChillPersonBundle/Entity/AccompanyingPeriod/Comment.php +++ b/src/Bundle/ChillPersonBundle/Entity/AccompanyingPeriod/Comment.php @@ -158,4 +158,9 @@ class Comment implements TrackCreationInterface, TrackUpdateInterface return $this; } + + public function isPinned(): bool + { + return $this->getAccompanyingPeriod()->getPinnedComment() === $this; + } }