foreach ( $fields as $key => $value ) {
if ( $value instanceof HTMLFormField ) {
- $v = isset( $this->mFieldData[$key] )
+ $v = array_key_exists( $key, $this->mFieldData )
? $this->mFieldData[$key]
: $value->getDefault();
$tmp = $m[1];
}
if ( substr( $tmp, 0, 2 ) == 'wp' &&
- !isset( $alldata[$tmp] ) &&
- isset( $alldata[substr( $tmp, 2 )] )
+ !array_key_exists( $tmp, $alldata ) &&
+ array_key_exists( substr( $tmp, 2 ), $alldata )
) {
// Adjust for name mangling.
$tmp = substr( $tmp, 2 );
$data = $alldata;
while ( $keys ) {
$key = array_shift( $keys );
- if ( !is_array( $data ) || !isset( $data[$key] ) ) {
+ if ( !is_array( $data ) || !array_key_exists( $key, $data ) ) {
continue 2;
}
$data = $data[$key];
$fields = $this->createFieldsForKey( $key );
foreach ( $fields as $fieldname => $field ) {
- $v = isset( $values[$fieldname] )
+ $v = array_key_exists( $fieldname, $values )
? $values[$fieldname]
: $field->getDefault();