@@ -19,8 +19,9 @@ |
||
| 19 | 19 | */ |
| 20 | 20 | public static function getInstance() |
| 21 | 21 | { |
| 22 | - if ( is_null( self::$instance ) ) |
|
| 23 | - self::$instance = new self(); |
|
| 22 | + if ( is_null( self::$instance ) ) { |
|
| 23 | + self::$instance = new self(); |
|
| 24 | + } |
|
| 24 | 25 | |
| 25 | 26 | return self::$instance; |
| 26 | 27 | } |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | foreach ( $brutArray as $value ) { |
| 59 | 59 | $value = trim( $value ); |
| 60 | 60 | if ( '' !== $value ) |
| 61 | - $newArray[] = $value; |
|
| 61 | + $newArray[ ] = $value; |
|
| 62 | 62 | } |
| 63 | 63 | |
| 64 | 64 | return $newArray; |
@@ -120,14 +120,14 @@ discard block |
||
| 120 | 120 | public static function addBacktick( $string ) |
| 121 | 121 | { |
| 122 | 122 | $string = str_replace( '`', '', $string ); |
| 123 | - $stringArrayBacktick = []; |
|
| 123 | + $stringArrayBacktick = [ ]; |
|
| 124 | 124 | $string = self::clearMultipleSpaces( $string ); |
| 125 | 125 | $stringArray = explode( '.', $string ); |
| 126 | 126 | foreach ( $stringArray as $part ) { |
| 127 | 127 | $part = self::clearMultipleSpaces( $part ); |
| 128 | 128 | if ( empty( $part ) ) |
| 129 | 129 | continue; |
| 130 | - $stringArrayBacktick[] = '`' . $part . '`'; |
|
| 130 | + $stringArrayBacktick[ ] = '`' . $part . '`'; |
|
| 131 | 131 | } |
| 132 | 132 | |
| 133 | 133 | return implode( '.', $stringArrayBacktick ); |
@@ -57,8 +57,9 @@ discard block |
||
| 57 | 57 | $newArray = array(); |
| 58 | 58 | foreach ( $brutArray as $value ) { |
| 59 | 59 | $value = trim( $value ); |
| 60 | - if ( '' !== $value ) |
|
| 61 | - $newArray[] = $value; |
|
| 60 | + if ( '' !== $value ) { |
|
| 61 | + $newArray[] = $value; |
|
| 62 | + } |
|
| 62 | 63 | } |
| 63 | 64 | |
| 64 | 65 | return $newArray; |
@@ -110,8 +111,9 @@ discard block |
||
| 110 | 111 | $characters = 'abcdefghijklmnopqrstuvwxyz'; |
| 111 | 112 | $charactersLength = strlen( $characters ); |
| 112 | 113 | $randomString = ''; |
| 113 | - for ( $i = 0; $i < $length; $i++ ) |
|
| 114 | - $randomString .= $characters[ rand( 0, $charactersLength - 1 ) ]; |
|
| 114 | + for ( $i = 0; $i < $length; $i++ ) { |
|
| 115 | + $randomString .= $characters[ rand( 0, $charactersLength - 1 ) ]; |
|
| 116 | + } |
|
| 115 | 117 | |
| 116 | 118 | return str_shuffle( $randomString ); |
| 117 | 119 | } |
@@ -125,8 +127,9 @@ discard block |
||
| 125 | 127 | $stringArray = explode( '.', $string ); |
| 126 | 128 | foreach ( $stringArray as $part ) { |
| 127 | 129 | $part = self::clearMultipleSpaces( $part ); |
| 128 | - if ( empty( $part ) ) |
|
| 129 | - continue; |
|
| 130 | + if ( empty( $part ) ) { |
|
| 131 | + continue; |
|
| 132 | + } |
|
| 130 | 133 | $stringArrayBacktick[] = '`' . $part . '`'; |
| 131 | 134 | } |
| 132 | 135 | |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | /** |
| 36 | 36 | * @var array |
| 37 | 37 | */ |
| 38 | - protected $usedInstanceIds = []; |
|
| 38 | + protected $usedInstanceIds = [ ]; |
|
| 39 | 39 | |
| 40 | 40 | /** |
| 41 | 41 | * @var string |
@@ -63,7 +63,7 @@ discard block |
||
| 63 | 63 | * @return $this |
| 64 | 64 | * @throws \Qpdb\QueryBuilder\Dependencies\QueryException |
| 65 | 65 | */ |
| 66 | - public function withBindParams( array $params = [] ) |
|
| 66 | + public function withBindParams( array $params = [ ] ) |
|
| 67 | 67 | { |
| 68 | 68 | $this->queryStructure->replaceElement( QueryStructure::BIND_PARAMS, $params ); |
| 69 | 69 | |
@@ -37,9 +37,9 @@ discard block |
||
| 37 | 37 | * @return array |
| 38 | 38 | */ |
| 39 | 39 | public function getSyntax( $replacement = self::REPLACEMENT_NONE ) { |
| 40 | - $queries = []; |
|
| 40 | + $queries = [ ]; |
|
| 41 | 41 | foreach ( $this->transaction as $queryStatement ) { |
| 42 | - $queries[] = $queryStatement->getSyntax( $replacement ); |
|
| 42 | + $queries[ ] = $queryStatement->getSyntax( $replacement ); |
|
| 43 | 43 | } |
| 44 | 44 | |
| 45 | 45 | return $queries; |
@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | * @param array $params |
| 51 | 51 | * @return mixed|null |
| 52 | 52 | */ |
| 53 | - public function executeFunction( \Closure $function, array $params = [] ) { |
|
| 53 | + public function executeFunction( \Closure $function, array $params = [ ] ) { |
|
| 54 | 54 | return PdoWrapperService::getInstance()->transaction( $function, $params ); |
| 55 | 55 | } |
| 56 | 56 | |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | * @return mixed|null |
| 59 | 59 | */ |
| 60 | 60 | public function execute() { |
| 61 | - $transaction = (array)$this->transaction; |
|
| 61 | + $transaction = ( array ) $this->transaction; |
|
| 62 | 62 | |
| 63 | 63 | return PdoWrapperService::getInstance()->transaction( |
| 64 | 64 | function() use ( $transaction ) { |
@@ -77,9 +77,9 @@ discard block |
||
| 77 | 77 | * @return array |
| 78 | 78 | */ |
| 79 | 79 | public function getBindParams() { |
| 80 | - $queries = []; |
|
| 80 | + $queries = [ ]; |
|
| 81 | 81 | foreach ( $this->transaction as $queryStatement ) { |
| 82 | - $queries[] = $queryStatement->getBindParams(); |
|
| 82 | + $queries[ ] = $queryStatement->getBindParams(); |
|
| 83 | 83 | } |
| 84 | 84 | |
| 85 | 85 | return $queries; |
@@ -53,37 +53,37 @@ discard block |
||
| 53 | 53 | /** |
| 54 | 54 | * Explain |
| 55 | 55 | */ |
| 56 | - $syntax[] = $this->getExplainSyntax(); |
|
| 56 | + $syntax[ ] = $this->getExplainSyntax(); |
|
| 57 | 57 | |
| 58 | 58 | /** |
| 59 | 59 | * UPDATE statement |
| 60 | 60 | */ |
| 61 | - $syntax[] = $this->statement; |
|
| 61 | + $syntax[ ] = $this->statement; |
|
| 62 | 62 | |
| 63 | 63 | /** |
| 64 | 64 | * PRIORITY |
| 65 | 65 | */ |
| 66 | - $syntax[] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 66 | + $syntax[ ] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 67 | 67 | |
| 68 | 68 | /** |
| 69 | 69 | * TABLE update |
| 70 | 70 | */ |
| 71 | - $syntax[] = 'FROM ' . $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 71 | + $syntax[ ] = 'FROM ' . $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 72 | 72 | |
| 73 | 73 | /** |
| 74 | 74 | * WHERE clause |
| 75 | 75 | */ |
| 76 | - $syntax[] = $this->getWhereSyntax(); |
|
| 76 | + $syntax[ ] = $this->getWhereSyntax(); |
|
| 77 | 77 | |
| 78 | 78 | /** |
| 79 | 79 | * ORDER BY clause |
| 80 | 80 | */ |
| 81 | - $syntax[] = $this->getOrderBySyntax(); |
|
| 81 | + $syntax[ ] = $this->getOrderBySyntax(); |
|
| 82 | 82 | |
| 83 | 83 | /** |
| 84 | 84 | * LIMIT clause |
| 85 | 85 | */ |
| 86 | - $syntax[] = $this->getLimitSyntax(); |
|
| 86 | + $syntax[ ] = $this->getLimitSyntax(); |
|
| 87 | 87 | |
| 88 | 88 | $syntax = implode( ' ', $syntax ); |
| 89 | 89 | |
@@ -99,7 +99,7 @@ discard block |
||
| 99 | 99 | if ( $this->queryStructure->getElement( ( QueryStructure::WHERE_TRIGGER ) ) && !count( $this->queryStructure->getElement( QueryStructure::WHERE ) ) ) |
| 100 | 100 | throw new QueryException( 'Where clause is required for this statement!', QueryException::QUERY_ERROR_DELETE_NOT_FILTER ); |
| 101 | 101 | |
| 102 | - return PdoWrapperService::getInstance()->query($this->getSyntax(), $this->queryStructure->getElement(QueryStructure::BIND_PARAMS))->rowCount(); |
|
| 102 | + return PdoWrapperService::getInstance()->query( $this->getSyntax(), $this->queryStructure->getElement( QueryStructure::BIND_PARAMS ) )->rowCount(); |
|
| 103 | 103 | } |
| 104 | 104 | |
| 105 | 105 | |
@@ -96,8 +96,9 @@ |
||
| 96 | 96 | */ |
| 97 | 97 | public function execute() |
| 98 | 98 | { |
| 99 | - if ( $this->queryStructure->getElement( ( QueryStructure::WHERE_TRIGGER ) ) && !count( $this->queryStructure->getElement( QueryStructure::WHERE ) ) ) |
|
| 100 | - throw new QueryException( 'Where clause is required for this statement!', QueryException::QUERY_ERROR_DELETE_NOT_FILTER ); |
|
| 99 | + if ( $this->queryStructure->getElement( ( QueryStructure::WHERE_TRIGGER ) ) && !count( $this->queryStructure->getElement( QueryStructure::WHERE ) ) ) { |
|
| 100 | + throw new QueryException( 'Where clause is required for this statement!', QueryException::QUERY_ERROR_DELETE_NOT_FILTER ); |
|
| 101 | + } |
|
| 101 | 102 | |
| 102 | 103 | return PdoWrapperService::getInstance()->query($this->getSyntax(), $this->queryStructure->getElement(QueryStructure::BIND_PARAMS))->rowCount(); |
| 103 | 104 | } |
@@ -56,8 +56,9 @@ discard block |
||
| 56 | 56 | $this->queryStructure->setElement( QueryStructure::TABLE, $tableName ); |
| 57 | 57 | |
| 58 | 58 | $tableSelectParams = $table->getBindParams(); |
| 59 | - foreach ( $tableSelectParams as $key => $value ) |
|
| 60 | - $this->queryStructure->setParams( $key, $value ); |
|
| 59 | + foreach ( $tableSelectParams as $key => $value ) { |
|
| 60 | + $this->queryStructure->setParams( $key, $value ); |
|
| 61 | + } |
|
| 61 | 62 | |
| 62 | 63 | } |
| 63 | 64 | } |
@@ -112,8 +113,9 @@ discard block |
||
| 112 | 113 | $this->queryStructure->setElement( QueryStructure::DISTINCT, 0 ); //??? |
| 113 | 114 | } |
| 114 | 115 | |
| 115 | - if ( $this->queryStructure->getElement( QueryStructure::FIRST ) ) |
|
| 116 | - $this->queryStructure->setElement( QueryStructure::LIMIT, 1 ); |
|
| 116 | + if ( $this->queryStructure->getElement( QueryStructure::FIRST ) ) { |
|
| 117 | + $this->queryStructure->setElement( QueryStructure::LIMIT, 1 ); |
|
| 118 | + } |
|
| 117 | 119 | |
| 118 | 120 | $syntax = array(); |
| 119 | 121 | |
@@ -120,62 +120,62 @@ discard block |
||
| 120 | 120 | /** |
| 121 | 121 | * Explain |
| 122 | 122 | */ |
| 123 | - $syntax[] = $this->getExplainSyntax(); |
|
| 123 | + $syntax[ ] = $this->getExplainSyntax(); |
|
| 124 | 124 | |
| 125 | 125 | /** |
| 126 | 126 | * SELECT statement |
| 127 | 127 | */ |
| 128 | - $syntax[] = $this->statement; |
|
| 128 | + $syntax[ ] = $this->statement; |
|
| 129 | 129 | |
| 130 | 130 | /** |
| 131 | 131 | * PRIORITY |
| 132 | 132 | */ |
| 133 | - $syntax[] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 133 | + $syntax[ ] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 134 | 134 | |
| 135 | 135 | /** |
| 136 | 136 | * DISTINCT clause |
| 137 | 137 | */ |
| 138 | - $syntax[] = $this->getDistinctSyntax(); |
|
| 138 | + $syntax[ ] = $this->getDistinctSyntax(); |
|
| 139 | 139 | |
| 140 | 140 | /** |
| 141 | 141 | * FIELDS |
| 142 | 142 | */ |
| 143 | - $syntax[] = $this->getSelectFieldsSyntax(); |
|
| 143 | + $syntax[ ] = $this->getSelectFieldsSyntax(); |
|
| 144 | 144 | |
| 145 | 145 | /** |
| 146 | 146 | * FROM table or queryStructure |
| 147 | 147 | */ |
| 148 | - $syntax[] = 'FROM ' . $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 148 | + $syntax[ ] = 'FROM ' . $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 149 | 149 | |
| 150 | 150 | /** |
| 151 | 151 | * JOIN CLAUSES |
| 152 | 152 | */ |
| 153 | - $syntax[] = $this->getJoinSyntax(); |
|
| 153 | + $syntax[ ] = $this->getJoinSyntax(); |
|
| 154 | 154 | |
| 155 | 155 | /** |
| 156 | 156 | * WHERE clause |
| 157 | 157 | */ |
| 158 | - $syntax[] = $this->getWhereSyntax(); |
|
| 158 | + $syntax[ ] = $this->getWhereSyntax(); |
|
| 159 | 159 | |
| 160 | 160 | /** |
| 161 | 161 | * GROUP BY clause |
| 162 | 162 | */ |
| 163 | - $syntax[] = $this->getGroupBySyntax(); |
|
| 163 | + $syntax[ ] = $this->getGroupBySyntax(); |
|
| 164 | 164 | |
| 165 | 165 | /** |
| 166 | 166 | * HAVING clause |
| 167 | 167 | */ |
| 168 | - $syntax[] = $this->getHavingSyntax(); |
|
| 168 | + $syntax[ ] = $this->getHavingSyntax(); |
|
| 169 | 169 | |
| 170 | 170 | /** |
| 171 | 171 | * ORDER BY clause |
| 172 | 172 | */ |
| 173 | - $syntax[] = $this->getOrderBySyntax(); |
|
| 173 | + $syntax[ ] = $this->getOrderBySyntax(); |
|
| 174 | 174 | |
| 175 | 175 | /** |
| 176 | 176 | * LIMIT clause |
| 177 | 177 | */ |
| 178 | - $syntax[] = $this->getLimitSyntax(); |
|
| 178 | + $syntax[ ] = $this->getLimitSyntax(); |
|
| 179 | 179 | |
| 180 | 180 | $syntax = implode( ' ', $syntax ); |
| 181 | 181 | |
@@ -200,7 +200,7 @@ discard block |
||
| 200 | 200 | case $this->queryStructure->getElement( QueryStructure::COLUMN ): |
| 201 | 201 | return PdoWrapperService::getInstance()->queryFetchAll( $this->getSyntax(), $this->queryStructure->getElement( QueryStructure::BIND_PARAMS ), \PDO::FETCH_COLUMN ); |
| 202 | 202 | default: |
| 203 | - return PdoWrapperService::getInstance()->queryFetchAll($this->getSyntax(), $this->queryStructure->getElement( QueryStructure::BIND_PARAMS ), \PDO::FETCH_ASSOC); |
|
| 203 | + return PdoWrapperService::getInstance()->queryFetchAll( $this->getSyntax(), $this->queryStructure->getElement( QueryStructure::BIND_PARAMS ), \PDO::FETCH_ASSOC ); |
|
| 204 | 204 | } |
| 205 | 205 | } |
| 206 | 206 | |
@@ -62,32 +62,32 @@ discard block |
||
| 62 | 62 | /** |
| 63 | 63 | * Explain |
| 64 | 64 | */ |
| 65 | - $syntax[] = $this->getExplainSyntax(); |
|
| 65 | + $syntax[ ] = $this->getExplainSyntax(); |
|
| 66 | 66 | |
| 67 | 67 | /** |
| 68 | 68 | * UPDATE statement |
| 69 | 69 | */ |
| 70 | - $syntax[] = $this->statement; |
|
| 70 | + $syntax[ ] = $this->statement; |
|
| 71 | 71 | |
| 72 | 72 | /** |
| 73 | 73 | * PRIORITY |
| 74 | 74 | */ |
| 75 | - $syntax[] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 75 | + $syntax[ ] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 76 | 76 | |
| 77 | 77 | /** |
| 78 | 78 | * IGNORE clause |
| 79 | 79 | */ |
| 80 | - $syntax[] = $this->queryStructure->getElement( QueryStructure::IGNORE ) ? 'IGNORE' : ''; |
|
| 80 | + $syntax[ ] = $this->queryStructure->getElement( QueryStructure::IGNORE ) ? 'IGNORE' : ''; |
|
| 81 | 81 | |
| 82 | 82 | /** |
| 83 | 83 | * INTO table |
| 84 | 84 | */ |
| 85 | - $syntax[] = 'INTO ' . $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 85 | + $syntax[ ] = 'INTO ' . $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 86 | 86 | |
| 87 | 87 | /** |
| 88 | 88 | * FIELDS update |
| 89 | 89 | */ |
| 90 | - $syntax[] = $this->getSettingFieldsSyntax(); |
|
| 90 | + $syntax[ ] = $this->getSettingFieldsSyntax(); |
|
| 91 | 91 | |
| 92 | 92 | $syntax = implode( ' ', $syntax ); |
| 93 | 93 | |
@@ -99,7 +99,7 @@ discard block |
||
| 99 | 99 | * @return bool|mixed|\PDOStatement |
| 100 | 100 | */ |
| 101 | 101 | public function execute() { |
| 102 | - return PdoWrapperService::getInstance()->query($this->getSyntax(), $this->queryStructure->getElement(QueryStructure::BIND_PARAMS))->rowCount(); |
|
| 102 | + return PdoWrapperService::getInstance()->query( $this->getSyntax(), $this->queryStructure->getElement( QueryStructure::BIND_PARAMS ) )->rowCount(); |
|
| 103 | 103 | } |
| 104 | 104 | |
| 105 | 105 | |
@@ -53,47 +53,47 @@ discard block |
||
| 53 | 53 | /** |
| 54 | 54 | * Explain |
| 55 | 55 | */ |
| 56 | - $syntax[] = $this->getExplainSyntax(); |
|
| 56 | + $syntax[ ] = $this->getExplainSyntax(); |
|
| 57 | 57 | |
| 58 | 58 | /** |
| 59 | 59 | * UPDATE statement |
| 60 | 60 | */ |
| 61 | - $syntax[] = $this->statement; |
|
| 61 | + $syntax[ ] = $this->statement; |
|
| 62 | 62 | |
| 63 | 63 | /** |
| 64 | 64 | * PRIORITY |
| 65 | 65 | */ |
| 66 | - $syntax[] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 66 | + $syntax[ ] = $this->queryStructure->getElement( QueryStructure::PRIORITY ); |
|
| 67 | 67 | |
| 68 | 68 | /** |
| 69 | 69 | * IGNORE clause |
| 70 | 70 | */ |
| 71 | - $syntax[] = $this->queryStructure->getElement( QueryStructure::IGNORE ) ? 'IGNORE' : ''; |
|
| 71 | + $syntax[ ] = $this->queryStructure->getElement( QueryStructure::IGNORE ) ? 'IGNORE' : ''; |
|
| 72 | 72 | |
| 73 | 73 | /** |
| 74 | 74 | * TABLE update |
| 75 | 75 | */ |
| 76 | - $syntax[] = $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 76 | + $syntax[ ] = $this->queryStructure->getElement( QueryStructure::TABLE ); |
|
| 77 | 77 | |
| 78 | 78 | /** |
| 79 | 79 | * FIELDS update |
| 80 | 80 | */ |
| 81 | - $syntax[] = $this->getSettingFieldsSyntax(); |
|
| 81 | + $syntax[ ] = $this->getSettingFieldsSyntax(); |
|
| 82 | 82 | |
| 83 | 83 | /** |
| 84 | 84 | * WHERE clause |
| 85 | 85 | */ |
| 86 | - $syntax[] = $this->getWhereSyntax(); |
|
| 86 | + $syntax[ ] = $this->getWhereSyntax(); |
|
| 87 | 87 | |
| 88 | 88 | /** |
| 89 | 89 | * ORDER BY clause |
| 90 | 90 | */ |
| 91 | - $syntax[] = $this->getOrderBySyntax(); |
|
| 91 | + $syntax[ ] = $this->getOrderBySyntax(); |
|
| 92 | 92 | |
| 93 | 93 | /** |
| 94 | 94 | * LIMIT clause |
| 95 | 95 | */ |
| 96 | - $syntax[] = $this->getLimitSyntax(); |
|
| 96 | + $syntax[ ] = $this->getLimitSyntax(); |
|
| 97 | 97 | |
| 98 | 98 | $syntax = implode( ' ', $syntax ); |
| 99 | 99 | |
@@ -110,6 +110,6 @@ discard block |
||
| 110 | 110 | if ( $this->queryStructure->getElement( ( QueryStructure::WHERE_TRIGGER ) ) && !count( $this->queryStructure->getElement( QueryStructure::WHERE ) ) ) |
| 111 | 111 | throw new QueryException( 'Where clause is required for this statement!', QueryException::QUERY_ERROR_DELETE_NOT_FILTER ); |
| 112 | 112 | |
| 113 | - return PdoWrapperService::getInstance()->query($this->getSyntax(), $this->queryStructure->getElement(QueryStructure::BIND_PARAMS))->rowCount(); |
|
| 113 | + return PdoWrapperService::getInstance()->query( $this->getSyntax(), $this->queryStructure->getElement( QueryStructure::BIND_PARAMS ) )->rowCount(); |
|
| 114 | 114 | } |
| 115 | 115 | } |
| 116 | 116 | \ No newline at end of file |
@@ -96,8 +96,9 @@ |
||
| 96 | 96 | */ |
| 97 | 97 | public function execute() |
| 98 | 98 | { |
| 99 | - if ( $this->queryStructure->getElement( ( QueryStructure::WHERE_TRIGGER ) ) && !count( $this->queryStructure->getElement( QueryStructure::WHERE ) ) ) |
|
| 100 | - throw new QueryException( 'Where clause is required for this statement!', QueryException::QUERY_ERROR_DELETE_NOT_FILTER ); |
|
| 99 | + if ( $this->queryStructure->getElement( ( QueryStructure::WHERE_TRIGGER ) ) && !count( $this->queryStructure->getElement( QueryStructure::WHERE ) ) ) { |
|
| 100 | + throw new QueryException( 'Where clause is required for this statement!', QueryException::QUERY_ERROR_DELETE_NOT_FILTER ); |
|
| 101 | + } |
|
| 101 | 102 | |
| 102 | 103 | return PdoWrapperService::getInstance()->query($this->getSyntax(), $this->queryStructure->getElement(QueryStructure::BIND_PARAMS))->rowCount(); |
| 103 | 104 | } |
@@ -305,7 +305,7 @@ discard block |
||
| 305 | 305 | * @return $this |
| 306 | 306 | * @throws \Qpdb\QueryBuilder\Dependencies\QueryException |
| 307 | 307 | */ |
| 308 | - public function havingExpression( $whereString, array $bindParams = [], $glue = 'AND' ) |
|
| 308 | + public function havingExpression( $whereString, array $bindParams = [ ], $glue = 'AND' ) |
|
| 309 | 309 | { |
| 310 | 310 | $whereString = $this->queryStructure->bindParamsExpression( $whereString, $bindParams ); |
| 311 | 311 | |
@@ -318,7 +318,7 @@ discard block |
||
| 318 | 318 | * @return $this |
| 319 | 319 | * @throws \Qpdb\QueryBuilder\Dependencies\QueryException |
| 320 | 320 | */ |
| 321 | - public function orHavingExpression( $whereString, array $bindParams = [] ) |
|
| 321 | + public function orHavingExpression( $whereString, array $bindParams = [ ] ) |
|
| 322 | 322 | { |
| 323 | 323 | $whereString = $this->queryStructure->bindParamsExpression( $whereString, $bindParams ); |
| 324 | 324 | |