Completed
Push — master ( f16f44...7a2452 )
by Andreas
21:05
created
src/midcom/datamanager/template/form.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
     public function form_end(FormView $view, array $data)
76 76
     {
77 77
         $string = '';
78
-        if (   !isset($data['render_rest'])
78
+        if (!isset($data['render_rest'])
79 79
             || $data['render_rest']) {
80 80
             $string .= $this->renderer->rest($view);
81 81
         }
@@ -166,7 +166,7 @@  discard block
 block discarded – undo
166 166
         $string .= '<div class="attachment-container">';
167 167
         $string .= '<div class="attachment-preview">';
168 168
         if (!empty($data['value']['filename'])) {
169
-            $ext = pathinfo($data['value']['filename'], PATHINFO_EXTENSION);;
169
+            $ext = pathinfo($data['value']['filename'], PATHINFO_EXTENSION); ;
170 170
             $string .= '<a href="' . $data['value']['url'] . '" target="_blank" class="icon" title="' . $data['value']['filename'] . '">';
171 171
             $string .= '<i class="fa fa-file-o"></i><span class="extension">' . $ext . '</span></a>';
172 172
         } else {
@@ -211,7 +211,7 @@  discard block
 block discarded – undo
211 211
             $data['attr']['class'] = 'shorttext';
212 212
         }
213 213
 
214
-        if (   !empty($data['value'])
214
+        if (!empty($data['value'])
215 215
             || is_numeric($data['value'])) {
216 216
             $data['attr']['value'] = $data['value'];
217 217
         }
@@ -256,7 +256,7 @@  discard block
 block discarded – undo
256 256
         $jsinit .= "midcom_helper_datamanager2_autocomplete.create_dm2_widget('{$element_id}_search_input', {$data['min_chars']});\n";
257 257
 
258 258
         $string = '<fieldset ' . $this->renderer->block($view, 'widget_container_attributes') . '>';
259
-        $string .=  $this->renderer->widget($view['selection']);
259
+        $string .= $this->renderer->widget($view['selection']);
260 260
         $string .= ' ' . $this->renderer->widget($view['search_input']);
261 261
         $string .= '</fieldset>';
262 262
         return $string . $this->jsinit($jsinit);
@@ -305,7 +305,7 @@  discard block
 block discarded – undo
305 305
         }
306 306
 
307 307
         $string = '<select ';
308
-        if (   $data['required']
308
+        if ($data['required']
309 309
             && null === $data['placeholder']
310 310
             && $data['placeholder_in_choices'] === false
311 311
             && $data['multiple'] === false) {
@@ -319,7 +319,7 @@  discard block
 block discarded – undo
319 319
         $string .= $this->renderer->block($view, 'widget_attributes', $data) . '>';
320 320
         if (null !== $data['placeholder']) {
321 321
             $string .= '<option value=""';
322
-            if (   $data['required']
322
+            if ($data['required']
323 323
                 && empty($data['value'])
324 324
                 && "0" !== $data['value']) {
325 325
                 $string .= ' selected="selected"';
@@ -469,7 +469,7 @@  discard block
 block discarded – undo
469 469
             $string .= '<label class="midcom_datamanager_photo_label">' . $this->renderer->humanize('delete photo') . ' ' . $this->renderer->widget($data['form']['delete']) . '</label>';
470 470
             $string .= '<ul>';
471 471
             foreach ($objects as $identifier => $info) {
472
-                if (   $info['size_x']
472
+                if ($info['size_x']
473 473
                     && $info['size_y']) {
474 474
                     $size = "{$info['size_x']}&times;{$info['size_y']}";
475 475
                 } else {
@@ -494,7 +494,7 @@  discard block
 block discarded – undo
494 494
         $string .= '</td></tr></table></div>';
495 495
         $string .= $this->renderer->row($data['form']['identifier']);
496 496
 
497
-        return $string . $this->jsinit('init_image_widget("' . $view->vars['id'] .'");');
497
+        return $string . $this->jsinit('init_image_widget("' . $view->vars['id'] . '");');
498 498
     }
499 499
 
500 500
     public function subform_widget(FormView $view, array $data)
Please login to merge, or discard this patch.
lib/midgard/admin/asgard/handler/object/permissions.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
         $tmp = $this->_object;
93 93
 
94 94
         $i = 0;
95
-        while (   !empty($tmp->guid)
95
+        while (!empty($tmp->guid)
96 96
                && !is_a($tmp, midcom_db_topic::class)
97 97
                && $i < 100) {
98 98
             // Get the parent; wishing eventually to get a topic
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
 
140 140
         $assignees = $this->load_assignees();
141 141
         $this->process_assignees($assignees, $schemadb);
142
-        $assignee_field =& $schemadb->get('privileges')->get_field('add_assignee');
142
+        $assignee_field = & $schemadb->get('privileges')->get_field('add_assignee');
143 143
 
144 144
         if (!$this->additional_assignee) {
145 145
             // Populate additional assignee selector
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
             }
186 186
             foreach ($this->_privileges as $privilege) {
187 187
                 $privilege_components = explode(':', $privilege);
188
-                if (   $privilege_components[0] == 'midcom'
188
+                if ($privilege_components[0] == 'midcom'
189 189
                     || $privilege_components[0] == 'midgard') {
190 190
                     // This is one of the core privileges, we handle it
191 191
                     $privilege_label = $privilege;
@@ -244,7 +244,7 @@  discard block
 block discarded – undo
244 244
                 if (is_object($assignee)) {
245 245
                     $label = $assignee->name;
246 246
                 } else {
247
-                    $label = $this->_l10n->get('ghost assignee for '. $privilege->assignee);
247
+                    $label = $this->_l10n->get('ghost assignee for ' . $privilege->assignee);
248 248
                 }
249 249
             }
250 250
 
Please login to merge, or discard this patch.