for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the MilioooMessageBundle package.
*
* (c) Michiel boeckaert <[email protected]>
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
namespace Miliooo\Messaging\Specifications;
use Miliooo\Messaging\User\ParticipantInterface;
/**
* This specification is responsible for deciding if a given user can send a message to a given recipient.
* The default implementation is to just return true.
* @author Michiel Boeckaert <[email protected]>
class CanMessageRecipientSpecification implements CanMessageRecipientInterface
{
protected $error;
* {@inheritdoc}
public function isSatisfiedBy(ParticipantInterface $currentParticipant, ParticipantInterface $recipient)
return true;
}
public function getErrorMessage()
return $this->error;