Method getValue should check the type of input inside InputFilter #6028

Closed
wants to merge 2 commits into
from

Conversation

Projects
None yet
2 participants
Contributor

spalax commented Mar 23, 2014

InputFilter::getValue works incorrect and finishes with error (Missing argument 1 for Zend\InputFilter\BaseInputFilter::getValue()) when InputFilter has nested InputFilters.

@spalax spalax Method getValue should check the type of input which it tries to getV…
…alue, if it is InputFilter then should return getValues
00f4777

@Ocramius Ocramius commented on an outdated diff Mar 24, 2014

tests/ZendTest/InputFilter/InputFilterTest.php
@@ -46,6 +46,25 @@ public function testCanAddUsingSpecification()
$this->assertInstanceOf('Zend\InputFilter\InputInterface', $foo);
}
+ public function testInputFilterDoesNotHandleNestedInputFilters()
@Ocramius

Ocramius Mar 24, 2014

Member

The test name should reflect what the success case is.

Contributor

spalax commented Mar 24, 2014

@Ocramius done

Ocramius added the InputFilter label Apr 2, 2014

Ocramius self-assigned this Apr 2, 2014

Ocramius added the bug label Apr 2, 2014

Ocramius added this to the 2.3.1 milestone Apr 2, 2014

Ocramius closed this in 9d25bfe Apr 2, 2014

@Ocramius Ocramius added a commit that referenced this pull request Apr 2, 2014

@Ocramius Ocramius Merge branch 'hotfix/#6028-baseinputfilter-nested-inputfilter-values'…
… into develop

Close #6028
Forward Port #6028
8cd997b

@gianarb gianarb pushed a commit to zendframework/zend-inputfilter that referenced this pull request May 15, 2015

@Ocramius Ocramius Merge branch 'hotfix/zendframework/zf2#6028-baseinputfilter-nested-in…
…putfilter-values'

Close zendframework/zendframework#6028
8790ff5

@gianarb gianarb pushed a commit to zendframework/zend-inputfilter that referenced this pull request May 15, 2015

@Ocramius Ocramius Merge branch 'hotfix/zendframework/zf2#6028-baseinputfilter-nested-in…
…putfilter-values' into develop

Close zendframework/zendframework#6028
Forward Port zendframework/zendframework#6028
27bfa30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment