Bug #7417
Missleading exception on wrong data type
Status: | Resolved | Start date: | 2010-04-22 | |
---|---|---|---|---|
Priority: | Must have | Due date: | ||
Assigned To: | - | % Done: | 100% |
|
Category: | Core | |||
Target version: | - | |||
Has patch: | Affected Flow version: |
Description
hi,
in a viewhelper I annotated an argument "array" but throw in an object. The missleading exception
@@
was thrown.
In Core/ViewHelper/AbstractViewHelper.php:295 validateArguments() tries to throw an "wrong type"-exception but generates a new exception itself by calling strval($this->arguments[$argumentName])
.
We should only output the argument's value if it's a human readable type though skipping objects and arrays.
Associated revisions
[+BUGFIX] Fluid (Core): Fixed misleading exception. Resolves #7417.
History
#1 Updated by Christian Müller about 5 years ago
- File fluid_issue_7417.diff added
Felix Oertel wrote:
hi,
in a viewhelper I annotated an argument "array" but throw in an object. The missleading exception
@@
was thrown.In Core/ViewHelper/AbstractViewHelper.php:295 validateArguments() tries to throw an "wrong type"-exception but generates a new exception itself by calling
strval($this->arguments[$argumentName])
.We should only output the argument's value if it's a human readable type though skipping objects and arrays.
Attached patch (against FLOW3 SVN) removes the "Value of argument:" sentence completely and strval is not called.
#2 Updated by Sebastian Kurfuerst about 5 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100
Applied in changeset r4508.