Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Commit

Permalink
Implement feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
davidwindell committed Mar 20, 2013
1 parent 8ee8264 commit e3ff016
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
7 changes: 1 addition & 6 deletions src/CollectionInputFilter.php
Original file line number Diff line number Diff line change
Expand Up @@ -125,14 +125,9 @@ public function setData($data)
*/
public function isValid()
{
$inputCollection = array();
$valid = true;

$i = 0;
while ($i <= $this->getCount() - 1) {
$inputCollection[] = $this->validationGroup ?: array_keys($this->inputs);
$i++;
}
$inputCollection = array_fill(0, $this->getCount(), $this->validationGroup ?: array_keys($this->inputs));

foreach ($inputCollection as $key => $inputs) {
$this->data = array();
Expand Down
4 changes: 2 additions & 2 deletions src/Factory.php
Original file line number Diff line number Diff line change
Expand Up @@ -234,8 +234,8 @@ public function createInputFilter($inputFilterSpecification)
}

if ($inputFilter instanceof CollectionInputFilter) {
if (isset($inputFilterSpecification['inputfilter'])) {
$inputFilter->setInputFilter($inputFilterSpecification['inputfilter']);
if (isset($inputFilterSpecification['input_filter'])) {
$inputFilter->setInputFilter($inputFilterSpecification['input_filter']);
}
if (isset($inputFilterSpecification['count'])) {
$inputFilter->setCount($inputFilterSpecification['count']);
Expand Down

0 comments on commit e3ff016

Please sign in to comment.