Commit 55d3f78
authored
fix: doctype of View::render violates contract (#38789)
The Illuminate\View\View class is implementing the Illuminate\Contracts\View\View contract which extends the Illuminate\Contracts\Support\Renderable contract. The renderable contract is ensuring a contract for the render method always return a string:
```php
/**
* Get the evaluated contents of the object.
*
* @return string
*/
public function render();
```
But the View class implementing the contract is specifying a return type violating the contract:
```php
/**
* Get the string contents of the view.
*
* @param callable|null $callback
* @return array|string
*
* @throws \Throwable
*/
public function render(callable $callback = null) {}
```1 parent 7d3151c commit 55d3f78
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
84 | | - | |
| 84 | + | |
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| |||
0 commit comments