Completed
Pull Request — master (#6)
by Kris
02:53
created
lib/Query/SelectBase.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
      * @access protected
102 102
      * @var    QueryBuilder
103 103
      */
104
-     protected $topQuery = null;
104
+        protected $topQuery = null;
105 105
 
106 106
     /**
107 107
      * Constructor
@@ -122,7 +122,7 @@  discard block
 block discarded – undo
122 122
         }
123 123
     }
124 124
 
125
-   /**
125
+    /**
126 126
      * Parse the columns arguments for the select query
127 127
      *
128 128
      * @access protected
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
      */
201 201
     public function count($alias)
202 202
     {
203
-         $this->columns[] = array(
203
+            $this->columns[] = array(
204 204
             'type'  => 'count',
205 205
             'alias' => $alias
206 206
         );
@@ -217,7 +217,7 @@  discard block
 block discarded – undo
217 217
      */
218 218
     public function sum($column, $alias)
219 219
     {
220
-         $this->columns[] = array(
220
+            $this->columns[] = array(
221 221
             'type'  => 'sum',
222 222
             'name'  => $column,
223 223
             'alias' => $alias
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
      */
236 236
     public function min($column, $alias)
237 237
     {
238
-         $this->columns[] = array(
238
+            $this->columns[] = array(
239 239
             'type'  => 'min',
240 240
             'name'  => $column,
241 241
             'alias' => $alias
@@ -253,7 +253,7 @@  discard block
 block discarded – undo
253 253
      */
254 254
     public function max($column, $alias)
255 255
     {
256
-         $this->columns[] = array(
256
+            $this->columns[] = array(
257 257
             'type'  => 'max',
258 258
             'name'  => $column,
259 259
             'alias' => $alias
Please login to merge, or discard this patch.
lib/Driver/DatabaseDriver.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -135,8 +135,8 @@
 block discarded – undo
135 135
      */
136 136
     public function escape($str)
137 137
     {
138
-       $list = explode('.', $str);
139
-       return implode('.', $this->escapeList($list));
138
+        $list = explode('.', $str);
139
+        return implode('.', $this->escapeList($list));
140 140
     }
141 141
 
142 142
     /**
Please login to merge, or discard this patch.
lib/Driver/Mysql/MysqlDriver.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
         $port    = !empty($settings['port'])     ?  ';port='.$settings['port']        : '';
90 90
         $dbname  = !empty($settings['database']) ?  ';dbname='.$settings['database']  : '';
91 91
         $options = [
92
-          //  \PDO::ATTR_EMULATE_PREPARES => false,
92
+            //  \PDO::ATTR_EMULATE_PREPARES => false,
93 93
         ];
94 94
 
95 95
         $this->pdo = new \PDO(
@@ -153,11 +153,11 @@  discard block
 block discarded – undo
153 153
     public function addForeignKey($fkName, $srcTable, $srcColumn, $refTable, $refColumn)
154 154
     {
155 155
         $sql = sprintf('ALTER TABLE %s ADD CONSTRAINT %s FOREIGN KEY (%s) REFERENCES %s(%s)',
156
-                       $this->escape($srcTable),
157
-                       $fkName,
158
-                       $this->escape($srcColumn),
159
-                       $this->escape($refTable),
160
-                       $this->escape($refColumn)
156
+                        $this->escape($srcTable),
157
+                        $fkName,
158
+                        $this->escape($srcColumn),
159
+                        $this->escape($refTable),
160
+                        $this->escape($refColumn)
161 161
         );
162 162
         return $this->prepareAndExecuteSql($sql);
163 163
     }
@@ -174,8 +174,8 @@  discard block
 block discarded – undo
174 174
     public function dropForeignKey($fkName, $tableName)
175 175
     {
176 176
         $sql = sprintf('ALTER TABLE %s DROP FOREIGN KEY %s',
177
-                       $this->escape($tableName),
178
-                       $fkName
177
+                        $this->escape($tableName),
178
+                        $fkName
179 179
         );
180 180
         return $this->prepareAndExecuteSql($sql);
181 181
     }
@@ -230,7 +230,7 @@  discard block
 block discarded – undo
230 230
                     "'" . $userPassword ."'"
231 231
         ));
232 232
         return $this->prepareAndExecuteSql($sql);
233
-   }
233
+    }
234 234
 
235 235
     /**
236 236
      * Drop a user
@@ -260,7 +260,7 @@  discard block
 block discarded – undo
260 260
      *
261 261
      * @return bool     True if the user has been granted, otherwise false. 
262 262
      */
263
-     public function grantUser($databaseName, $userName)
263
+        public function grantUser($databaseName, $userName)
264 264
     {
265 265
         $sql = trim(sprintf('GRANT ALL ON %s.* TO %s@%s; FLUSH PRIVILEGES;', 
266 266
             $this->escape($databaseName),
Please login to merge, or discard this patch.