From 012aa045e9ceb1eefcdd2d0358f930bef3485274 Mon Sep 17 00:00:00 2001 From: Timo Tijhof Date: Wed, 22 May 2019 23:38:45 +0100 Subject: [PATCH] HTMLForm: Improve method documentation for setCollapsibleOptions() Follows-up 36d33daa03a63. Previously the method was described as "Set whether the form can be collapsed" taking a single boolean. Yet, the boolean did not influence whether the form can be collapsed, as one might expect. Rather, this method always enable collapsible mode. The thing that is set based on the passed value is the default state of that (unconditionally) enabled collapsible mode. Change-Id: I2e73d5481c44ed43769553b2bc25543a702c19b8 --- includes/htmlform/HTMLForm.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/htmlform/HTMLForm.php b/includes/htmlform/HTMLForm.php index f5be83fc1a..504202845a 100644 --- a/includes/htmlform/HTMLForm.php +++ b/includes/htmlform/HTMLForm.php @@ -1062,10 +1062,10 @@ class HTMLForm extends ContextSource { } /** - * Set whether the HTML form can be collapsed. + * Enable collapsible mode, and set whether the form is collapsed by default. * * @since 1.34 - * @param bool $collapsedByDefault (optional) whether the form is collapsed by default + * @param bool $collapsedByDefault Whether the form is collapsed by default (optional). * @return HTMLForm $this for chaining calls */ public function setCollapsibleOptions( $collapsedByDefault = false ) { -- 2.20.1