@@ -41,7 +41,9 @@ discard block |
||
41 | 41 | |
42 | 42 | public function setValueFromModel($model) |
43 | 43 | { |
44 | - if (property_exists($model, $this->name)) $this->value = $model->{$this->name}; |
|
44 | + if (property_exists($model, $this->name)) { |
|
45 | + $this->value = $model->{$this->name}; |
|
46 | + } |
|
45 | 47 | } |
46 | 48 | |
47 | 49 | public function setValueFromRequest($request) |
@@ -51,7 +53,9 @@ discard block |
||
51 | 53 | |
52 | 54 | public function fillModelWithValue($model) |
53 | 55 | { |
54 | - if (property_exists($model, $this->name)) $model->{$this->name} = $this->value; |
|
56 | + if (property_exists($model, $this->name)) { |
|
57 | + $model->{$this->name} = $this->value; |
|
58 | + } |
|
55 | 59 | } |
56 | 60 | |
57 | 61 | public function validateRequired() |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | $this->configure($config); |
25 | 25 | |
26 | 26 | $this->setPath(); |
27 | - } |
|
27 | + } |
|
28 | 28 | |
29 | 29 | /** |
30 | 30 | * Configure the plugin. |
@@ -69,11 +69,11 @@ discard block |
||
69 | 69 | * |
70 | 70 | * @return array |
71 | 71 | */ |
72 | - public function templatePaths() |
|
73 | - { |
|
74 | - $path = $this->path('templates'); |
|
75 | - return [$path]; |
|
76 | - } |
|
72 | + public function templatePaths() |
|
73 | + { |
|
74 | + $path = $this->path('templates'); |
|
75 | + return [$path]; |
|
76 | + } |
|
77 | 77 | |
78 | 78 | /** |
79 | 79 | * Trigger an event callback. This allows |