Bug #35338

Action arguments of type DateTime throw Exception

Added by Bastian Waidelich almost 9 years ago. Updated over 8 years ago.

Status:
Resolved
Priority:
Must have
Category:
Validation
Start date:
2012-03-28
Due date:
% Done:

100%

Estimated time:
PHP Version:
Has patch:
No
Complexity:

Description

If an action argument is an object, the ValidationResolver tries to instantiates that object to use it as Validator without checking the Interface.
So a simple controller action like following

public function someAction(\DateTime $date) {
}


Provokes an exception DateTime::__construct() expects parameter 1 to be string, array given


Related issues

Is duplicate of TYPO3.Flow - Bug #34048: ResolveValidator breaks on DateTime method argumentsClosedBastian Waidelich2012-02-17

Actions
#1

Updated by Gerrit Code Review almost 9 years ago

  • Status changed from Accepted to Under Review

Patch set 1 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10069

#2

Updated by Gerrit Code Review almost 9 years ago

Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10069

#3

Updated by Gerrit Code Review almost 9 years ago

Patch set 3 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10069

#4

Updated by Gerrit Code Review almost 9 years ago

Patch set 4 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10069

#5

Updated by Gerrit Code Review almost 9 years ago

Patch set 5 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10069

#6

Updated by Gerrit Code Review almost 9 years ago

Patch set 6 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10069

#7

Updated by Karsten Dambekalns almost 9 years ago

  • Status changed from Under Review to Closed

Closing as duplicate of #35338.

#8

Updated by Karsten Dambekalns almost 9 years ago

  • Status changed from Closed to Under Review
  • Target version changed from 1.1 to 1.0.5

Karsten Dambekalns wrote:

Closing as duplicate of #35338.

I have seen this once already, that closing a related bug closes the "other side" as well. Pffft.

#9

Updated by Bastian Waidelich almost 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
#10

Updated by Gerrit Code Review over 8 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch FLOW3-1.0 has been pushed to the review server.
It is available at http://review.typo3.org/11834

#11

Updated by Bastian Waidelich over 8 years ago

  • Status changed from Under Review to Resolved

Also available in: Atom PDF