diff options
| author | Greg Roach <greg@subaqua.co.uk> | 2022-11-27 19:54:24 +0000 |
|---|---|---|
| committer | Greg Roach <greg@subaqua.co.uk> | 2022-11-27 19:54:24 +0000 |
| commit | ac71572d8462e396ed5a307f05b29381e49f9e6e (patch) | |
| tree | d2055c1abc4f46dd6168eb7f2aad9e2efe7f1aa2 /app/Contracts/ResponseFactoryInterface.php | |
| parent | b112142ef0330ffced39153e5d475e1ea4f936ae (diff) | |
| download | webtrees-ac71572d8462e396ed5a307f05b29381e49f9e6e.tar.gz webtrees-ac71572d8462e396ed5a307f05b29381e49f9e6e.tar.bz2 webtrees-ac71572d8462e396ed5a307f05b29381e49f9e6e.zip | |
PHP 8.0 - Union types
Diffstat (limited to 'app/Contracts/ResponseFactoryInterface.php')
| -rw-r--r-- | app/Contracts/ResponseFactoryInterface.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/Contracts/ResponseFactoryInterface.php b/app/Contracts/ResponseFactoryInterface.php index 2ca7f4a551..cd7559dbdc 100644 --- a/app/Contracts/ResponseFactoryInterface.php +++ b/app/Contracts/ResponseFactoryInterface.php @@ -48,12 +48,12 @@ interface ResponseFactoryInterface /** * Redirect to a URL. * - * @param string|UriInterface $url + * @param UriInterface|string $url * @param int $code * * @return ResponseInterface */ - public function redirectUrl($url, int $code = StatusCodeInterface::STATUS_FOUND): ResponseInterface; + public function redirectUrl(UriInterface|string $url, int $code = StatusCodeInterface::STATUS_FOUND): ResponseInterface; /** * @param string|array<mixed>|object $content @@ -62,7 +62,7 @@ interface ResponseFactoryInterface * * @return ResponseInterface */ - public function response($content = '', int $code = StatusCodeInterface::STATUS_OK, array $headers = []): ResponseInterface; + public function response(string|array|object $content = '', int $code = StatusCodeInterface::STATUS_OK, array $headers = []): ResponseInterface; /** * Create and render a view, and embed it in an HTML page. |
