Passed
Branchmaster (991622)
by Plamen
01:31
created
thead.php 1 patch
Spacing   +6 added lines, -10 removed lines patch added patch discarded remove patch
@@ -48,9 +48,8 @@  discard block
 block discarded – undo
48 48
 
49 49
     private static function tagAttributes($tag, $items)
50 50
     {
51
-        $attr = $tag==='div' ?
52
-                ['id' => $items . '-list', 'class' => 'table'] : 
53
-                ['id' => $items . '-table', 'data-table' => 'js'];
51
+        $attr = $tag === 'div' ?
52
+                ['id' => $items . '-list', 'class' => 'table'] : ['id' => $items . '-table', 'data-table' => 'js'];
54 53
         if (array_key_exists($tag, self::$attributes)) {
55 54
             $attr += self::$attributes[$tag];
56 55
         }
@@ -87,8 +86,7 @@  discard block
 block discarded – undo
87 86
         if (isset($arg['width'])) { // Width attribute -> style
88 87
             $width = 'width:' . $arg['width'] . ';';
89 88
             $arg['style'] = isset($arg['style']) ?
90
-                    $width . $arg['style'] :
91
-                    $width;
89
+                    $width . $arg['style'] : $width;
92 90
         }
93 91
 
94 92
         if (($del = isset($arg['type']) && $arg['type'] == 'delete')) {
@@ -99,10 +97,9 @@  discard block
 block discarded – undo
99 97
         }
100 98
 
101 99
         $sort = $sortable ?
102
-                (isset($arg['sort']) ? $arg['sort'] : $col) :
103
-                null;
100
+                (isset($arg['sort']) ? $arg['sort'] : $col) : null;
104 101
 
105
-        return array_diff_key((array) $arg, ['sort', 'type', 'width']);
102
+        return array_diff_key((array)$arg, ['sort', 'type', 'width']);
106 103
     }
107 104
 
108 105
     private static function th($i, $attr, $sort, $del, $lbl)
@@ -114,8 +111,7 @@  discard block
 block discarded – undo
114 111
         if (!$del) {
115 112
             if ($sort == self::$t['order']['col']) {
116 113
                 $span = self::$t['order']['dir'] === 'desc' ?
117
-                        self::config('UTF8_DESC_SYMBOL') :
118
-                        self::config('UTF8_ASC_SYMBOL');
114
+                        self::config('UTF8_DESC_SYMBOL') : self::config('UTF8_ASC_SYMBOL');
119 115
             } else {
120 116
                 $span = "";
121 117
             }
Please login to merge, or discard this patch.