@@ -34,7 +34,7 @@ |
||
34 | 34 | public function addStructureInterface($interface) |
35 | 35 | { |
36 | 36 | if ($interface instanceof TemplateProperty) { |
37 | - $interface = (string)$interface; |
|
37 | + $interface = (string) $interface; |
|
38 | 38 | if (empty($interface)) { |
39 | 39 | throw new InvalidArgumentException( |
40 | 40 | 'Invalid template structure interface' |
@@ -118,7 +118,7 @@ |
||
118 | 118 | protected function loadNewsFromPath(Container $container) |
119 | 119 | { |
120 | 120 | if (!$this->news) { |
121 | - $config = $this->config(); |
|
121 | + $config = $this->config(); |
|
122 | 122 | $type = (isset($config['obj_type']) ? $config['obj_type'] : $this->objType); |
123 | 123 | $model = $container['model/factory']->create($type); |
124 | 124 |
@@ -118,7 +118,7 @@ |
||
118 | 118 | protected function loadEventFromPath(Container $container) |
119 | 119 | { |
120 | 120 | if (!$this->event) { |
121 | - $config = $this->config(); |
|
121 | + $config = $this->config(); |
|
122 | 122 | $type = (isset($config['obj_type']) ? $config['obj_type'] : $this->objType); |
123 | 123 | $model = $container['model/factory']->create($type); |
124 | 124 |
@@ -88,8 +88,8 @@ |
||
88 | 88 | return $response->withStatus(404); |
89 | 89 | } |
90 | 90 | |
91 | - $templateIdent = (string)$section->templateIdent(); |
|
92 | - $templateController = (string)$section->templateIdent(); |
|
91 | + $templateIdent = (string) $section->templateIdent(); |
|
92 | + $templateController = (string) $section->templateIdent(); |
|
93 | 93 | |
94 | 94 | if (!$templateController) { |
95 | 95 | return $response->withStatus(404); |
@@ -55,7 +55,7 @@ |
||
55 | 55 | } |
56 | 56 | |
57 | 57 | /** |
58 | - * @return mixed |
|
58 | + * @return string[] |
|
59 | 59 | */ |
60 | 60 | public function name() |
61 | 61 | { |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | { |
35 | 35 | parent::__construct($data); |
36 | 36 | |
37 | - if (is_callable([ $this, 'defaultData' ])) { |
|
37 | + if (is_callable([$this, 'defaultData'])) { |
|
38 | 38 | $this->setData($this->defaultData()); |
39 | 39 | } |
40 | 40 | } |
@@ -88,9 +88,9 @@ discard block |
||
88 | 88 | parent::validate($v); |
89 | 89 | |
90 | 90 | foreach ($this->translator()->locales() as $locale => $value) { |
91 | - if (!(string)$this->name()[$locale]) { |
|
91 | + if (!(string) $this->name()[$locale]) { |
|
92 | 92 | $this->validator()->error( |
93 | - (string)$this->translator()->translation([ |
|
93 | + (string) $this->translator()->translation([ |
|
94 | 94 | 'fr' => 'Le NOM doit être rempli dans toutes les langues.', |
95 | 95 | 'en' => 'The NAME must be filled in all languages.', |
96 | 96 | ]) |
@@ -3,7 +3,6 @@ |
||
3 | 3 | namespace Charcoal\Cms; |
4 | 4 | |
5 | 5 | // From 'charcoal-cms' |
6 | -use Charcoal\Cms\AbstractNew; |
|
7 | 6 | use Charcoal\Cms\NewsCategory; |
8 | 7 | |
9 | 8 | /** |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | // From 'charcoal-cms' |
6 | 6 | use Charcoal\Cms\AbstractSection; |
7 | -use Charcoal\Cms\Mixin\ContentSectionInterface; |
|
8 | 7 | |
9 | 8 | /** |
10 | 9 | * Content section |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | // From 'charcoal-cms' |
6 | 6 | use Charcoal\Cms\AbstractSection; |
7 | -use Charcoal\Cms\Mixin\EmptySectionInterface; |
|
8 | 7 | |
9 | 8 | /** |
10 | 9 | * Empty section |
@@ -74,7 +74,7 @@ |
||
74 | 74 | /** |
75 | 75 | * The tag's color. |
76 | 76 | * |
77 | - * @return mixed |
|
77 | + * @return string |
|
78 | 78 | */ |
79 | 79 | public function color() |
80 | 80 | { |