Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Fetching contributors…
Cannot retrieve contributors at this time
34 lines (26 sloc) 714 Bytes
* This file is part of the Symfony package.
* (c) Fabien Potencier <>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
namespace Symfony\Component\Validator\Constraints;
use Symfony\Component\Validator\Constraint;
use Symfony\Component\Validator\ConstraintValidator;
class TrueValidator extends ConstraintValidator
public function isValid($value, Constraint $constraint)
if (null === $value) {
return true;
if (!$value) {
return false;
return true;
Jump to Line
Something went wrong with that request. Please try again.