From: Timo Tijhof Date: Wed, 22 May 2019 22:38:45 +0000 (+0100) Subject: HTMLForm: Improve method documentation for setCollapsibleOptions() X-Git-Tag: 1.34.0-rc.0~1616^2 X-Git-Url: https://git.cyclocoop.org/%27.WWW_URL.%27admin/?a=commitdiff_plain;h=012aa045e9ceb1eefcdd2d0358f930bef3485274;p=lhc%2Fweb%2Fwiklou.git 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 --- 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 ) {