Skip to content

Commit

Permalink
Merge pull request #5 from timkung/pulls/validate-fix
Browse files Browse the repository at this point in the history
fixing validate method to return false and making PSR-2 compliant
  • Loading branch information
camspiers committed Oct 21, 2015
2 parents 3e3a28b + 3b7fd21 commit 297dee3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions code/HoneyPotField.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ public function validate($validator)
$validator->validationError(
$this->name,
"This field should not be completed",
"validation",
false
"validation"
);

return false;
}

return true;
Expand All @@ -23,4 +23,4 @@ public function FieldHolder($properties = array())
return $this->renderWith('HoneyPotField_holder');
}

}
}
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "camspiers/honeypot",
"type": "silverstripe-module",
"require": {
"silverstripe/spamprotection": "~1.2.0",
"silverstripe/spamprotection": "~2.0.0",
"composer/installers": "~1.0"
}
}

0 comments on commit 297dee3

Please sign in to comment.