Merge "Fix return type hints in media related classes"
[lhc/web/wiklou.git] / includes / libs / ParamValidator / TypeDef / PasswordDef.php
1 <?php
2
3 namespace Wikimedia\ParamValidator\TypeDef;
4
5 use Wikimedia\ParamValidator\ParamValidator;
6
7 /**
8 * Type definition for "password" types
9 *
10 * This is a string type that forces PARAM_SENSITIVE = true.
11 *
12 * @see StringDef
13 * @since 1.34
14 */
15 class PasswordDef extends StringDef {
16
17 public function normalizeSettings( array $settings ) {
18 $settings[ParamValidator::PARAM_SENSITIVE] = true;
19 return parent::normalizeSettings( $settings );
20 }
21
22 }