From bd84f4e6a021bcba3bd251155153fc6dcaaa6801 Mon Sep 17 00:00:00 2001 From: Alexandre Emsenhuber Date: Fri, 25 Jul 2008 18:06:29 +0000 Subject: [PATCH] Per r38036: also fix FormOptions --- includes/FormOptions.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/FormOptions.php b/includes/FormOptions.php index 5888a0c431..262c8c7fb5 100644 --- a/includes/FormOptions.php +++ b/includes/FormOptions.php @@ -176,8 +176,8 @@ class FormOptions implements ArrayAccess { throw new MWException( 'Unsupported datatype' ); } - if ( $value !== $default && $value !== null ) { - $this->options[$name]['value'] = $value; + if ( $value !== null ) { + $this->options[$name]['value'] = $value === $default ? null : $value; } } } -- 2.20.1