Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x

ProtectedUserFieldConstraint.php

Namespace

Drupal\user\Plugin\Validation\Constraint

File

core/modules/user/src/Plugin/Validation/Constraint/ProtectedUserFieldConstraint.php

View source
<?php

namespace Drupal\user\Plugin\Validation\Constraint;

use Drupal\Core\StringTranslation\TranslatableMarkup;
use Drupal\Core\Validation\Attribute\Constraint;
use Symfony\Component\Validator\Constraint as SymfonyConstraint;

/**
 * Checks if the plain text password is provided for editing a protected field.
 */
class ProtectedUserFieldConstraint extends SymfonyConstraint {
    
    /**
     * Violation message.
     *
     * @var string
     */
    public $message = "Your current password is missing or incorrect; it's required to change the %name.";

}

Classes

Title Deprecated Summary
ProtectedUserFieldConstraint Checks if the plain text password is provided for editing a protected field.

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal