Fix some issues with HTMLSelectAndOtherField default and validation
authorThalia <thalia.e.chan@googlemail.com>
Thu, 13 Jun 2019 19:04:49 +0000 (20:04 +0100)
committerThalia <thalia.e.chan@googlemail.com>
Sat, 15 Jun 2019 09:34:36 +0000 (10:34 +0100)
commitdb9ff28e3ebe87ed965561d4458841b7aad095c9
treea02a14c73d9f2956bb9ef85d4f2c2a39d8a3ccdd
parentbd1d2b8529501d00080c534e245479747a097604
Fix some issues with HTMLSelectAndOtherField default and validation

Bring HTMLSelectAndOtherField in line with other HTMLFormFields by
ensuring that the default value is of the correct type and passes
validation checks.

Also make sure HTMLSelectAndOtherField::validate checks for the
final value, if the field has required set to true.

Bug: T222170
Bug: T225860
Change-Id: I949ee3df2b1f597982cf522b149c54b8e79d59bc
includes/htmlform/fields/HTMLSelectAndOtherField.php