diff options
Diffstat (limited to 'lib/classes/forms')
| -rw-r--r-- | lib/classes/forms/Form.php | 2 | ||||
| -rw-r--r-- | lib/classes/forms/Link.php | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/classes/forms/Form.php b/lib/classes/forms/Form.php index 75323b9..4ffd86b 100644 --- a/lib/classes/forms/Form.php +++ b/lib/classes/forms/Form.php @@ -502,7 +502,7 @@ class Form extends Part * @return string * @throws \Flexi\TemplateNotFoundException */ - public function render(string|Template $layout = null) + public function render(string|Template|null $layout = null) { \NotificationCenter::postNotification('FormWillRender', $this); if (\Request::isDialog()) { diff --git a/lib/classes/forms/Link.php b/lib/classes/forms/Link.php index eeb0244..e198c71 100644 --- a/lib/classes/forms/Link.php +++ b/lib/classes/forms/Link.php @@ -11,7 +11,7 @@ class Link extends Part protected $icon; protected $attributes = []; - public function __construct(string $url, string $label, \Icon $icon = null) + public function __construct(string $url, string $label, ?\Icon $icon = null) { $this->url = $url; $this->label = $label; @@ -67,7 +67,7 @@ class Link extends Part * @param \Icon $icon * @return $this */ - public function setIcon(\Icon $icon = null): Link + public function setIcon(?\Icon $icon = null): Link { $this->icon = $icon; return $this; |
