From 2ce927788a875d2cf94bb86b1e509134df6642dd Mon Sep 17 00:00:00 2001 From: My6UoT9 Date: Mon, 21 Sep 2020 13:56:52 +0200 Subject: [PATCH] Update phpdoc for widget->getId (#18295) The private variable `$_id` is only set when `$autogenerate` is true, else it stays null, and will be returned by the function. --- framework/base/Widget.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/base/Widget.php b/framework/base/Widget.php index d578ae485a..c9850cd8ce 100644 --- a/framework/base/Widget.php +++ b/framework/base/Widget.php @@ -156,7 +156,7 @@ class Widget extends Component implements ViewContextInterface /** * Returns the ID of the widget. * @param bool $autoGenerate whether to generate an ID if it is not set previously - * @return string ID of the widget. + * @return string|null ID of the widget. */ public function getId($autoGenerate = true) {