Passed
Push — main ( 3310d4...08974e )
by Thierry
02:20
created
src/Driver/Facades/SelectFacade.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -19,12 +19,12 @@  discard block
 block discarded – undo
19 19
     /**
20 20
      * @var SelectQuery|null
21 21
      */
22
-    private SelectQuery|null $selectQuery = null;
22
+    private SelectQuery | null $selectQuery = null;
23 23
 
24 24
     /**
25 25
      * @var SelectResult|null
26 26
      */
27
-    private SelectResult|null $selectResult = null;
27
+    private SelectResult | null $selectResult = null;
28 28
 
29 29
     /**
30 30
      * @param AbstractFacade $dbFacade
@@ -97,8 +97,8 @@  discard block
 block discarded – undo
97 97
         try {
98 98
             $query = $this->driver->getRowCountQuery($table, $selectEntity->where,
99 99
                 $hasGroupsInFields, $selectEntity->group);
100
-            return (int)$this->driver->result($query);
101
-        } catch(Exception) {
100
+            return (int) $this->driver->result($query);
101
+        } catch (Exception) {
102 102
             return -1;
103 103
         }
104 104
     }
Please login to merge, or discard this patch.
src/Page/Dql/SelectResult.php 1 patch
Spacing   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -48,8 +48,7 @@  discard block
 block discarded – undo
48 48
         $value = $selectEntity->queryOptions["columns"][$valueKey] ?? [];
49 49
 
50 50
         $fun = $value["fun"] ?? '';
51
-        $fieldKey = !$selectEntity->select ? $key :
52
-            ($value["col"] ?? current($selectEntity->select));
51
+        $fieldKey = !$selectEntity->select ? $key : ($value["col"] ?? current($selectEntity->select));
53 52
         $field = $selectEntity->fields[$fieldKey];
54 53
         $name = !$field ? ($fun ? "*" : $key) : $this->page->fieldName($field, $position);
55 54
 
@@ -178,8 +177,7 @@  discard block
 block discarded – undo
178 177
     private function getRowIdMd5Key(string $key, string $collation): string
179 178
     {
180 179
         return $this->driver->jush() !== 'sql' ||
181
-            preg_match("~^utf8~", $collation) ? $key :
182
-                "CONVERT($key USING " . $this->driver->charset() . ")";
180
+            preg_match("~^utf8~", $collation) ? $key : "CONVERT($key USING " . $this->driver->charset() . ")";
183 181
     }
184 182
 
185 183
     /**
Please login to merge, or discard this patch.