From a0bd6b4b654e842c3dc5f606c2d1b180a9bd1803 Mon Sep 17 00:00:00 2001 From: Sukhwinder Dhillon Date: Wed, 30 Nov 2022 18:10:08 +0100 Subject: [PATCH] SelectElement: Add missing phpdoc --- src/FormElement/SelectElement.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/FormElement/SelectElement.php b/src/FormElement/SelectElement.php index 784cc44e..1c9b29f0 100644 --- a/src/FormElement/SelectElement.php +++ b/src/FormElement/SelectElement.php @@ -26,13 +26,13 @@ class SelectElement extends BaseFormElement /** @var array Disabled select options */ protected $disabledOptions = []; - /** @var array|string */ + /** @var array|string|null */ protected $value; /** * Get the option with specified value * - * @param string|int $value + * @param string|int|null $value * * @return SelectOption * @@ -96,7 +96,9 @@ public function setDisabledOptions(array $disabledOptions): self /** * Get the value of the element * - * Returns `array` when the attribute `multiple` is set to `true`, `string` otherwise + * Returns `array` when the attribute `multiple` is set to `true`, `string` or `null` otherwise + * + * @return array|string|null */ public function getValue() { @@ -123,7 +125,7 @@ public function getNameAttribute() /** * Make the selectOption for the specified value and the label * - * @param string|int $value Value of the option + * @param string|int|null $value Value of the option * @param string|array $label Label of the option * * @return SelectOption|HtmlElement @@ -152,9 +154,9 @@ protected function makeOption($value, $label) } /** - * Whether the given option is a selected option + * Get whether the given option is selected * - * @param int|string $optionValue + * @param int|string|null $optionValue * * @return bool */