@@ -277,7 +277,7 @@ discard block |
||
| 277 | 277 | $tables[$row['database']][$row['table']][$node] = $row; |
| 278 | 278 | } |
| 279 | 279 | $result['replicas'][$node] = $r; |
| 280 | - }catch (\Exception $E) { |
|
| 280 | + } catch (\Exception $E) { |
|
| 281 | 281 | $result['replicas'][$node] = false; |
| 282 | 282 | $badNodes[$node] = $E->getMessage(); |
| 283 | 283 | $this->error[] = 'statementsReplicas:' . $E->getMessage(); |
@@ -299,7 +299,7 @@ discard block |
||
| 299 | 299 | ]; |
| 300 | 300 | } |
| 301 | 301 | |
| 302 | - }catch (\Exception $E) { |
|
| 302 | + } catch (\Exception $E) { |
|
| 303 | 303 | $result['clusters'][$node] = false; |
| 304 | 304 | |
| 305 | 305 | $this->error[] = 'clusters:' . $E->getMessage(); |
@@ -293,8 +293,9 @@ |
||
| 293 | 293 | |
| 294 | 294 | if (stripos($format, 'json') !== false) |
| 295 | 295 | { |
| 296 | - if (stripos($format,'JSONEachRow')===false) |
|
| 297 | - return $this->json(); |
|
| 296 | + if (stripos($format,'JSONEachRow')===false) { |
|
| 297 | + return $this->json(); |
|
| 298 | + } |
|
| 298 | 299 | } |
| 299 | 300 | return $this->body(); |
| 300 | 301 | |
@@ -226,8 +226,7 @@ discard block |
||
| 226 | 226 | if ($key=='data') |
| 227 | 227 | { |
| 228 | 228 | $data=$this->_rawData[$key]; |
| 229 | - } |
|
| 230 | - else{ |
|
| 229 | + } else{ |
|
| 231 | 230 | $this->{$key} = $this->_rawData[$key]; |
| 232 | 231 | } |
| 233 | 232 | |
@@ -247,8 +246,7 @@ discard block |
||
| 247 | 246 | if ($isJSONCompact) |
| 248 | 247 | { |
| 249 | 248 | $r[]=$rows; |
| 250 | - } |
|
| 251 | - else { |
|
| 249 | + } else { |
|
| 252 | 250 | foreach ($this->meta as $meta) { |
| 253 | 251 | $r[$meta['name']] = $rows[$meta['name']]; |
| 254 | 252 | } |
@@ -634,8 +634,9 @@ |
||
| 634 | 634 | |
| 635 | 635 | return $response; |
| 636 | 636 | } finally { |
| 637 | - if ($streamRW->isWrite()) |
|
| 638 | - fclose($stream); |
|
| 637 | + if ($streamRW->isWrite()) { |
|
| 638 | + fclose($stream); |
|
| 639 | + } |
|
| 639 | 640 | } |
| 640 | 641 | } |
| 641 | 642 | |