Newscoop\Services\SubscriptionService::getOneByUserAndPublication PHP Method

getOneByUserAndPublication() public method

public getOneByUserAndPublication ( $userId, $publicationId )
    public function getOneByUserAndPublication($userId, $publicationId)
    {
        $subscription = $this->em->getRepository('Newscoop\\Subscription\\Subscription')->findOneBy(array('user' => $userId, 'publication' => $publicationId));
        return $subscription;
    }