Skip to content

Commit f8e435b

Browse files
Refactored getData method.
1 parent e972f59 commit f8e435b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/ModelValidator.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,10 +149,11 @@ protected function getRules()
149149
*/
150150
protected function getData()
151151
{
152+
$data = $this->model->getAttributes();
152153
if (method_exists($this->model, 'validationData')) {
153-
return $this->model->validationData();
154+
return $this->model->validationData($data);
154155
}
155156

156-
return $this->model->getAttributes();
157+
return $data;
157158
}
158159
}

0 commit comments

Comments
 (0)