From 0fca0d7f965fd771b950712de9f68ebaeb3d57dd Mon Sep 17 00:00:00 2001 From: Eugene Mosunov Date: Wed, 13 Mar 2019 10:12:17 +0500 Subject: [PATCH] Fix issue with getting validation rules when updating not from special method --- src/Services/EntityService.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Services/EntityService.php b/src/Services/EntityService.php index 4a0d450..cf8f04e 100644 --- a/src/Services/EntityService.php +++ b/src/Services/EntityService.php @@ -119,7 +119,7 @@ public function update(Model $model, array $modelParams): Model */ protected function getValidationRulesForAttributes(array $modelParams, array $rules = []): array { - $modelRules = empty($rules) ? $this->repository->getModelValidationRules() : $rules; + $modelRules = empty($rules) ? $this->getValidationRules() : $rules; return array_intersect_key($modelRules, $modelParams); }