@@ -36,11 +36,11 @@ discard block |
||
| 36 | 36 | |
| 37 | 37 | $stm = $this->connection->prepare($query); |
| 38 | 38 | |
| 39 | - try{ |
|
| 39 | + try { |
|
| 40 | 40 | $stm->execute(); |
| 41 | 41 | } |
| 42 | - catch(\PDOException $exception){ |
|
| 43 | - throw new DatabaseException($exception->getMessage() . ' [' . $query . ']'); |
|
| 42 | + catch (\PDOException $exception) { |
|
| 43 | + throw new DatabaseException($exception->getMessage().' ['.$query.']'); |
|
| 44 | 44 | } |
| 45 | 45 | |
| 46 | 46 | return ResultSet::make($stm); |
@@ -56,17 +56,17 @@ discard block |
||
| 56 | 56 | |
| 57 | 57 | $dsn = 'mysql:'; |
| 58 | 58 | if (isset($params['host']) && $params['host'] != '') { |
| 59 | - $dsn .= 'host=' . $params['host'] . ';'; |
|
| 59 | + $dsn .= 'host='.$params['host'].';'; |
|
| 60 | 60 | } |
| 61 | 61 | if (isset($params['port'])) { |
| 62 | - $dsn .= 'port=' . $params['port'] . ';'; |
|
| 62 | + $dsn .= 'port='.$params['port'].';'; |
|
| 63 | 63 | } |
| 64 | 64 | if (isset($params['charset'])) { |
| 65 | - $dsn .= 'charset=' . $params['charset'] . ';'; |
|
| 65 | + $dsn .= 'charset='.$params['charset'].';'; |
|
| 66 | 66 | } |
| 67 | 67 | |
| 68 | 68 | if (isset($params['socket']) && $params['socket'] != '') { |
| 69 | - $dsn .= 'unix_socket=' . $params['socket'] . ';'; |
|
| 69 | + $dsn .= 'unix_socket='.$params['socket'].';'; |
|
| 70 | 70 | } |
| 71 | 71 | |
| 72 | 72 | try { |
@@ -109,7 +109,7 @@ discard block |
||
| 109 | 109 | try { |
| 110 | 110 | $statement = $this->connection->query(implode(';', $queue)); |
| 111 | 111 | } catch (\PDOException $exception) { |
| 112 | - throw new DatabaseException($exception->getMessage() .' [ '.implode(';', $queue).']'); |
|
| 112 | + throw new DatabaseException($exception->getMessage().' [ '.implode(';', $queue).']'); |
|
| 113 | 113 | } |
| 114 | 114 | |
| 115 | 115 | return MultiResultSet::make($statement); |
@@ -38,8 +38,7 @@ |
||
| 38 | 38 | |
| 39 | 39 | try{ |
| 40 | 40 | $stm->execute(); |
| 41 | - } |
|
| 42 | - catch(\PDOException $exception){ |
|
| 41 | + } catch(\PDOException $exception){ |
|
| 43 | 42 | throw new DatabaseException($exception->getMessage() . ' [' . $query . ']'); |
| 44 | 43 | } |
| 45 | 44 | |