Upgrade to 3.9.1

This commit is contained in:
Bastian Allgeier
2023-01-31 11:10:44 +01:00
parent 6e5c9d1f48
commit c58864a585
54 changed files with 633 additions and 465 deletions

View File

@@ -1612,13 +1612,11 @@ class App
* Uses the snippet component to create
* and return a template snippet
*
* @param mixed $name
* @param array|object $data Variables or an object that becomes `$item`
* @param bool $return On `false`, directly echo the snippet
* @return string|null
* @psalm-return ($return is true ? string : null)
*/
public function snippet($name, $data = [], bool $return = true, bool $slots = false): Snippet|string|null
public function snippet(string|array|null $name, $data = [], bool $return = true, bool $slots = false): Snippet|string|null
{
if (is_object($data) === true) {
$data = ['item' => $data];