/**
  * @param $subject
  */
 public function remove($subject)
 {
     if (!$this->isExists($subject)) {
         return;
     }
     $this->favoriteManager->toggle($subject, $this->loader);
 }
 /**
  * {@inheritdoc}
  */
 public function getTests()
 {
     return [new \Twig_SimpleTest('favorite', function ($value) {
         return $this->manager->isFavorite($value);
     })];
 }