Move validator methods

This commit is contained in:
Frederic Guillot
2016-01-14 20:18:13 -05:00
parent dc35a78374
commit 805be7d331
33 changed files with 605 additions and 477 deletions

View File

@@ -78,7 +78,7 @@ class Comment extends Base
$values = $this->request->getValues();
$ajax = $this->request->isAjax() || $this->request->getIntegerParam('ajax');
list($valid, $errors) = $this->comment->validateCreation($values);
list($valid, $errors) = $this->commentValidator->validateCreation($values);
if ($valid) {
if ($this->comment->create($values)) {
@@ -127,7 +127,7 @@ class Comment extends Base
$comment = $this->getComment();
$values = $this->request->getValues();
list($valid, $errors) = $this->comment->validateModification($values);
list($valid, $errors) = $this->commentValidator->validateModification($values);
if ($valid) {
if ($this->comment->update($values)) {