Overtrue\Validation\Validator::validateSame PHP Méthode

validateSame() protected méthode

Validate that two attributes match.
protected validateSame ( string $attribute, mixed $value, array $parameters ) : boolean
$attribute string
$value mixed
$parameters array
Résultat boolean
    protected function validateSame($attribute, $value, $parameters)
    {
        $this->requireParameterCount(1, $parameters, 'same');
        $other = array_get($this->data, $parameters[0]);
        return isset($other) && $value === $other;
    }
Validator