@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | /** |
15 | 15 | * @param array $data |
16 | 16 | */ |
17 | - public function __construct(array $data = []) |
|
17 | + public function __construct(array $data = [ ]) |
|
18 | 18 | { |
19 | 19 | $this->populate($data); |
20 | 20 | } |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | * @param array $properties |
32 | 32 | * @return array |
33 | 33 | */ |
34 | - public function extract(array $properties = []) |
|
34 | + public function extract(array $properties = [ ]) |
|
35 | 35 | { |
36 | 36 | $state = get_object_vars($this); |
37 | 37 | |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | * @param array $array |
49 | 49 | * @return $this |
50 | 50 | */ |
51 | - public function populate(array $array = []) |
|
51 | + public function populate(array $array = [ ]) |
|
52 | 52 | { |
53 | 53 | $state = get_object_vars($this); |
54 | 54 |
@@ -7,7 +7,7 @@ |
||
7 | 7 | /** |
8 | 8 | * @var array |
9 | 9 | */ |
10 | - private $errors = []; |
|
10 | + private $errors = [ ]; |
|
11 | 11 | |
12 | 12 | /** |
13 | 13 | * @param array $errors |
@@ -47,7 +47,7 @@ |
||
47 | 47 | $entity = $this->repository->find($criteria); |
48 | 48 | |
49 | 49 | if (!$entity) { |
50 | - $this->setErrors(['general' => sprintf("Entity #%s does not found.", $id)]); |
|
50 | + $this->setErrors([ 'general' => sprintf("Entity #%s does not found.", $id) ]); |
|
51 | 51 | return; |
52 | 52 | } |
53 | 53 |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | $entity = $this->repository->find($criteria); |
47 | 47 | |
48 | 48 | if (!$entity) { |
49 | - $this->setErrors(['general' => sprintf("Entity #%s does not found.", $id)]); |
|
49 | + $this->setErrors([ 'general' => sprintf("Entity #%s does not found.", $id) ]); |
|
50 | 50 | return; |
51 | 51 | } |
52 | 52 | |
@@ -69,13 +69,13 @@ discard block |
||
69 | 69 | * @param array $filter |
70 | 70 | * @return EntityInterface[]|null |
71 | 71 | */ |
72 | - public function deleteAll(array $filter = []) |
|
72 | + public function deleteAll(array $filter = [ ]) |
|
73 | 73 | { |
74 | 74 | $criteria = $this->repository->createCriteria($filter); |
75 | 75 | $entities = $this->repository->findMany($criteria); |
76 | 76 | |
77 | 77 | if (empty($entities)) { |
78 | - $this->setErrors(['general' => 'Entities does not found.']); |
|
78 | + $this->setErrors([ 'general' => 'Entities does not found.' ]); |
|
79 | 79 | return; |
80 | 80 | } |
81 | 81 |