Passed
Push — master ( 5379a4...a2888f )
by Joao
04:49
created
src/Database/DBSQLRelayDriver.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@
 block discarded – undo
56 56
             sqlrcur_prepareQuery($cur, $sql);
57 57
             $bindCount = 1;
58 58
             foreach ($array as $key => $value) {
59
-                $field = strval($bindCount ++);
59
+                $field = strval($bindCount++);
60 60
                 sqlrcur_inputBind($cur, $field, $value);
61 61
             }
62 62
             $success = sqlrcur_executeQuery($cur);
Please login to merge, or discard this patch.
src/ConnectionManagement.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -181,14 +181,14 @@
 block discarded – undo
181 181
         $pat = "/$patDriver($patCredentials$patHost$patDatabase|$patFile)$patExtra/i";
182 182
         $parts = array();
183 183
         if (!preg_match($pat, $this->getDbConnectionString(), $parts)) {
184
-            throw new InvalidArgumentException("Connection string " . $this->getDbConnectionString() . " is invalid! Please fix it.");
184
+            throw new InvalidArgumentException("Connection string ".$this->getDbConnectionString()." is invalid! Please fix it.");
185 185
         }
186 186
 
187 187
         // Set the Driver
188 188
         $this->setDriver($parts ['driver']);
189 189
 
190 190
         if (!isset($parts['path']) && !isset($parts['host'])) {
191
-            throw new InvalidArgumentException("Connection string " . $this->getDbConnectionString() . " is invalid! Please fix it.");
191
+            throw new InvalidArgumentException("Connection string ".$this->getDbConnectionString()." is invalid! Please fix it.");
192 192
         }
193 193
 
194 194
 
Please login to merge, or discard this patch.
src/Database/PdoObdc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@
 block discarded – undo
10 10
 
11 11
     public function __construct(ConnectionManagement $connMngt)
12 12
     {
13
-        $strcnn = $connMngt->getDriver() . ":" . $connMngt->getServer();
13
+        $strcnn = $connMngt->getDriver().":".$connMngt->getServer();
14 14
 
15 15
         parent::__construct($connMngt, $strcnn, [], []);
16 16
     }
Please login to merge, or discard this patch.
src/Database/SQLBind.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@
 block discarded – undo
47 47
             $arg = str_replace("_", SQLBind::keyAdj($key), $paramSubstName);
48 48
 
49 49
             $count = 0;
50
-            $sql = preg_replace("/(\[\[$key\]\]|:" . $key . "[\s\W]|:$key\$)/", $arg . ' ', $sql, -1, $count);
50
+            $sql = preg_replace("/(\[\[$key\]\]|:".$key."[\s\W]|:$key\$)/", $arg.' ', $sql, -1, $count);
51 51
             if ($count === 0) {
52 52
                 unset($params[$key]);
53 53
             }
Please login to merge, or discard this patch.
src/Database/PdoOci.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
 
13 13
     public function __construct(ConnectionManagement $connMngt)
14 14
     {
15
-        $strcnn = $connMngt->getDriver() . ":dbname=" . DBOci8Driver::getTnsString($connMngt);
15
+        $strcnn = $connMngt->getDriver().":dbname=".DBOci8Driver::getTnsString($connMngt);
16 16
 
17 17
         $postOptions = [
18 18
             PDO::ATTR_EMULATE_PREPARES => true
Please login to merge, or discard this patch.
src/Database/BaseDBAccess.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -86,8 +86,8 @@  discard block
 block discarded – undo
86 86
         $start = 0;
87 87
         if ($debug) {
88 88
             $log = LogHandler::getInstance();
89
-            $log->debug("Class name: " . get_class($this));
90
-            $log->debug("SQL: " . $sql);
89
+            $log->debug("Class name: ".get_class($this));
90
+            $log->debug("SQL: ".$sql);
91 91
             if (!is_null($param)) {
92 92
                 $s = "";
93 93
                 foreach ($param as $key => $value) {
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
 
111 111
         if ($debug) {
112 112
             $end = microtime(true);
113
-            $log->debug("Execution time: " . ($end - $start) . " seconds ");
113
+            $log->debug("Execution time: ".($end - $start)." seconds ");
114 114
         }
115 115
 
116 116
         return $id;
@@ -131,8 +131,8 @@  discard block
 block discarded – undo
131 131
         $start = 0;
132 132
         if ($debug) {
133 133
             $log = LogHandler::getInstance();
134
-            $log->debug("Class name: " . get_class($this));
135
-            $log->debug("SQL: " . $sql);
134
+            $log->debug("Class name: ".get_class($this));
135
+            $log->debug("SQL: ".$sql);
136 136
             if (!is_null($param)) {
137 137
                 $s = "";
138 138
                 foreach ($param as $key => $value) {
@@ -148,7 +148,7 @@  discard block
 block discarded – undo
148 148
         $it = $db->getIterator($sql, $param, $ttl);
149 149
         if ($debug) {
150 150
             $end = microtime(true);
151
-            $log->debug("Execution Time: " . ($end - $start) . " segundos ");
151
+            $log->debug("Execution Time: ".($end - $start)." segundos ");
152 152
         }
153 153
         return $it;
154 154
     }
@@ -161,8 +161,8 @@  discard block
 block discarded – undo
161 161
         $start = 0;
162 162
         if ($debug) {
163 163
             $log = LogHandler::getInstance();
164
-            $log->debug("Class name: " . get_class($this));
165
-            $log->debug("SQL: " . $sql);
164
+            $log->debug("Class name: ".get_class($this));
165
+            $log->debug("SQL: ".$sql);
166 166
             if (!is_null($param)) {
167 167
                 $s = "";
168 168
                 foreach ($param as $key => $value) {
@@ -178,7 +178,7 @@  discard block
 block discarded – undo
178 178
         $scalar = $this->_db->getScalar($sql, $param);
179 179
         if ($debug) {
180 180
             $end = microtime(true);
181
-            $log->debug("Execution Time: " . ($end - $start) . " segundos ");
181
+            $log->debug("Execution Time: ".($end - $start)." segundos ");
182 182
         }
183 183
         return $scalar;
184 184
     }
@@ -262,14 +262,14 @@  discard block
 block discarded – undo
262 262
                     $fields = $sr->getFieldNames();
263 263
                 }
264 264
 
265
-                $line .= '"' . implode('","', $fields) . '"' . "\n";
265
+                $line .= '"'.implode('","', $fields).'"'."\n";
266 266
             }
267 267
 
268 268
             $raw = array();
269 269
             foreach ($fields as $field) {
270 270
                 $raw[] = $sr->getField($field);
271 271
             }
272
-            $line .= '"' . implode('","', array_values($raw)) . '"' . "\n";
272
+            $line .= '"'.implode('","', array_values($raw)).'"'."\n";
273 273
 
274 274
             if ($echoToBrowser) {
275 275
                 echo $line;
Please login to merge, or discard this patch.
src/Database/DBOci8Driver.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -63,9 +63,9 @@
 block discarded – undo
63 63
 
64 64
         $host = $connMngt->getServer();
65 65
 
66
-        $tns = "(DESCRIPTION = " .
67
-            "	(ADDRESS = (PROTOCOL = $protocol)(HOST = $host)(PORT = $port)) " .
68
-            "		(CONNECT_DATA = (SERVICE_NAME = $svcName)) " .
66
+        $tns = "(DESCRIPTION = ".
67
+            "	(ADDRESS = (PROTOCOL = $protocol)(HOST = $host)(PORT = $port)) ".
68
+            "		(CONNECT_DATA = (SERVICE_NAME = $svcName)) ".
69 69
             ")";
70 70
 
71 71
         return $tns;
Please login to merge, or discard this patch.
src/Repository/IteratorFilter.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
         if ($xpathFilter == "") {
38 38
             return "/anydataset/row";
39 39
         } else {
40
-            return "/anydataset/row[" . $xpathFilter . "]";
40
+            return "/anydataset/row[".$xpathFilter."]";
41 41
         }
42 42
     }
43 43
 
@@ -136,33 +136,33 @@  discard block
 block discarded – undo
136 136
     private function getStrXpathRelation($name, $relation, $value)
137 137
     {
138 138
         $str = is_numeric($value) ? "" : "'";
139
-        $field = "field[@name='" . $name . "'] ";
139
+        $field = "field[@name='".$name."'] ";
140 140
         $value = " $str$value$str ";
141 141
 
142 142
         $result = "";
143 143
         switch ($relation) {
144 144
             case Relation::EQUAL: {
145
-                    $result = $field . "=" . $value;
145
+                    $result = $field."=".$value;
146 146
                     break;
147 147
                 }
148 148
             case Relation::GREATER_THAN: {
149
-                    $result = $field . ">" . $value;
149
+                    $result = $field.">".$value;
150 150
                     break;
151 151
                 }
152 152
             case Relation::LESS_THAN: {
153
-                    $result = $field . "<" . $value;
153
+                    $result = $field."<".$value;
154 154
                     break;
155 155
                 }
156 156
             case Relation::GREATER_OR_EQUAL_THAN: {
157
-                    $result = $field . ">=" . $value;
157
+                    $result = $field.">=".$value;
158 158
                     break;
159 159
                 }
160 160
             case Relation::LESS_OR_EQUAL_THAN: {
161
-                    $result = $field . "<=" . $value;
161
+                    $result = $field."<=".$value;
162 162
                     break;
163 163
                 }
164 164
             case Relation::NOT_EQUAL: {
165
-                    $result = $field . "!=" . $value;
165
+                    $result = $field."!=".$value;
166 166
                     break;
167 167
                 }
168 168
             case Relation::STARTS_WITH: {
@@ -191,47 +191,47 @@  discard block
 block discarded – undo
191 191
         $paramName = $name;
192 192
         $i = 0;
193 193
         while (array_key_exists($paramName, $param)) {
194
-            $paramName = $name . ($i++);
194
+            $paramName = $name.($i++);
195 195
         }
196 196
 
197 197
         $param[$paramName] = $value;
198 198
 
199 199
         $result = "";
200 200
         $field = " $name ";
201
-        $valueparam = " [[" . $paramName . "]] ";
201
+        $valueparam = " [[".$paramName."]] ";
202 202
         switch ($relation) {
203 203
             case Relation::EQUAL: {
204
-                    $result = $field . "=" . $valueparam;
204
+                    $result = $field."=".$valueparam;
205 205
                     break;
206 206
                 }
207 207
             case Relation::GREATER_THAN: {
208
-                    $result = $field . ">" . $valueparam;
208
+                    $result = $field.">".$valueparam;
209 209
                     break;
210 210
                 }
211 211
             case Relation::LESS_THAN: {
212
-                    $result = $field . "<" . $valueparam;
212
+                    $result = $field."<".$valueparam;
213 213
                     break;
214 214
                 }
215 215
             case Relation::GREATER_OR_EQUAL_THAN: {
216
-                    $result = $field . ">=" . $valueparam;
216
+                    $result = $field.">=".$valueparam;
217 217
                     break;
218 218
                 }
219 219
             case Relation::LESS_OR_EQUAL_THAN: {
220
-                    $result = $field . "<=" . $valueparam;
220
+                    $result = $field."<=".$valueparam;
221 221
                     break;
222 222
                 }
223 223
             case Relation::NOT_EQUAL: {
224
-                    $result = $field . "!=" . $valueparam;
224
+                    $result = $field."!=".$valueparam;
225 225
                     break;
226 226
                 }
227 227
             case Relation::STARTS_WITH: {
228
-                    $param[$paramName] = $value . "%";
229
-                    $result = $field . " like " . $valueparam;
228
+                    $param[$paramName] = $value."%";
229
+                    $result = $field." like ".$valueparam;
230 230
                     break;
231 231
                 }
232 232
             case Relation::CONTAINS: {
233
-                    $param[$paramName] = "%" . $value . "%";
234
-                    $result = $field . " like " . $valueparam;
233
+                    $param[$paramName] = "%".$value."%";
234
+                    $result = $field." like ".$valueparam;
235 235
                     break;
236 236
                 }
237 237
         }
Please login to merge, or discard this patch.
src/Repository/SocketDataset.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -54,8 +54,8 @@
 block discarded – undo
54 54
         if (!$handle) {
55 55
             throw new DatasetException("Socket error: $errstr ($errno)");
56 56
         } else {
57
-            $out = "GET " . $this->_path . " HTTP/1.1\r\n";
58
-            $out .= "Host: " . $this->_server . "\r\n";
57
+            $out = "GET ".$this->_path." HTTP/1.1\r\n";
58
+            $out .= "Host: ".$this->_server."\r\n";
59 59
             $out .= "Connection: Close\r\n\r\n";
60 60
 
61 61
             fwrite($handle, $out);
Please login to merge, or discard this patch.