Feature #4405
EmptyView is misleading
| Status: | Resolved | Start date: | 2009-08-31 | |
|---|---|---|---|---|
| Priority: | Should have | Due date: | ||
| Assignee: | Karsten Dambekalns | % Done: | 100% |
|
| Category: | MVC | |||
| Target version: | TYPO3 Flow Base Distribution - 1.0 alpha 5 | |||
| PHP Version: | Complexity: | |||
| Has patch: | ||||
| Votes: | 0 |
Description
When no template is found, FLOW3 uses \F3\FLOW3\MVC\View\EmptyView as view (see ActionController::resolveView()).
Instead we should use the NotFoundView that was introduced in r2888 to display a more meaningful error to the user.
So instead of:
if ($viewObjectName === FALSE) $viewObjectName = 'F3\FLOW3\MVC\View\EmptyView';
something like
if ($viewObjectName === FALSE) {
$view = $this->objectManager->getObject('F3\FLOW3\MVC\View\NotFoundView');
$view->assign('errorMessage', 'dummdidumm');
}
Then EmptyView could be removed I guess..
Associated revisions
[+FEATURE] FLOW3 (MVC): Removed EmptyView and made NotFoundView display helpful message instead, resolves #4405.
History
Updated by Bastian Waidelich over 3 years ago
Bastian Waidelich wrote:
Then EmptyView could be removed I guess..
The empty magic call method from EmptyView should be added to the NotFoundView to prevent PHP from issuing a fatal error when calling non-existing methods.
Updated by Bastian Waidelich over 3 years ago
- Assignee set to Bastian Waidelich
I'll provide a patch with the suggested changes
Updated by Bastian Waidelich over 3 years ago
- File 4405_EmptyView_is_misleading.patch added
- File 4405_Testing.patch added
- Assignee changed from Bastian Waidelich to Robert Lemke
Attached patches replaces EmptyView by NotFoundView in ActionController. Additionally it removes the no longer needed(?) EmptyView.
@Robert: Please validate the patches
Updated by Karsten Dambekalns over 3 years ago
- Status changed from New to Accepted
- Assignee changed from Robert Lemke to Karsten Dambekalns
- Target version set to 1.0 alpha 5
Updated by Karsten Dambekalns over 3 years ago
- Status changed from Accepted to Resolved
- % Done changed from 0 to 100
Applied in changeset r3212.