Completed
Push — v5 ( b778e1...e7c877 )
by Georges
02:38
created
src/phpFastCache/Drivers/Ssdb/Driver.php 3 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -147,10 +147,10 @@
 block discarded – undo
147 147
     {
148 148
         try{
149 149
             $server = isset($this->config[ 'ssdb' ]) ? $this->config[ 'ssdb' ] : [
150
-              'host' => "127.0.0.1",
151
-              'port' => 8888,
152
-              'password' => '',
153
-              'timeout' => 2000,
150
+                'host' => "127.0.0.1",
151
+                'port' => 8888,
152
+                'password' => '',
153
+                'timeout' => 2000,
154 154
             ];
155 155
 
156 156
             $host = $server[ 'host' ];
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -145,18 +145,18 @@  discard block
 block discarded – undo
145 145
      */
146 146
     public function driverConnect()
147 147
     {
148
-        try{
149
-            $server = isset($this->config[ 'ssdb' ]) ? $this->config[ 'ssdb' ] : [
148
+        try {
149
+            $server = isset($this->config['ssdb']) ? $this->config['ssdb'] : [
150 150
               'host' => "127.0.0.1",
151 151
               'port' => 8888,
152 152
               'password' => '',
153 153
               'timeout' => 2000,
154 154
             ];
155 155
 
156
-            $host = $server[ 'host' ];
157
-            $port = isset($server[ 'port' ]) ? (int) $server[ 'port' ] : 8888;
158
-            $password = isset($server[ 'password' ]) ? $server[ 'password' ] : '';
159
-            $timeout = !empty($server[ 'timeout' ]) ? (int) $server[ 'timeout' ] : 2000;
156
+            $host = $server['host'];
157
+            $port = isset($server['port']) ? (int) $server['port'] : 8888;
158
+            $password = isset($server['password']) ? $server['password'] : '';
159
+            $timeout = !empty($server['timeout']) ? (int) $server['timeout'] : 2000;
160 160
             $this->instance = new SimpleSSDB($host, $port, $timeout);
161 161
             if (!empty($password)) {
162 162
                 $this->instance->auth($password);
@@ -167,8 +167,8 @@  discard block
 block discarded – undo
167 167
             } else {
168 168
                 return true;
169 169
             }
170
-        }catch(SSDBException $e){
171
-            throw new phpFastCacheDriverException('Ssdb failed to connect with error: '. $e->getMessage(), 0 , $e);
170
+        } catch (SSDBException $e) {
171
+            throw new phpFastCacheDriverException('Ssdb failed to connect with error: ' . $e->getMessage(), 0, $e);
172 172
         }
173 173
     }
174 174
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -167,7 +167,7 @@
 block discarded – undo
167 167
             } else {
168 168
                 return true;
169 169
             }
170
-        }catch(SSDBException $e){
170
+        } catch(SSDBException $e){
171 171
             throw new phpFastCacheDriverException('Ssdb failed to connect with error: '. $e->getMessage(), 0 , $e);
172 172
         }
173 173
     }
Please login to merge, or discard this patch.