@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | switch (gettype($c)) { |
| 47 | 47 | case 'array'; |
| 48 | 48 | foreach ($c as $k => $v) { |
| 49 | - self::$config[$k] = self::getValid((string) $k, $v); |
|
| 49 | + self::$config[$k] = self::getValid((string)$k, $v); |
|
| 50 | 50 | } |
| 51 | 51 | break; |
| 52 | 52 | case 'string': |
@@ -97,7 +97,7 @@ discard block |
||
| 97 | 97 | |
| 98 | 98 | private static function qConditions(&$q, $cond, $h) |
| 99 | 99 | { |
| 100 | - if(!empty($cond)){ |
|
| 100 | + if (!empty($cond)) { |
|
| 101 | 101 | $clause = !$h ? 'WHERE' : 'HAVING'; |
| 102 | 102 | $clue = !strpos($q, $clause) ? $clause : 'AND'; |
| 103 | 103 | $q .= (' ' . $clue . ' ' . $cond); |
@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | |
| 107 | 107 | private static function qOrder(&$q, $order) |
| 108 | 108 | { |
| 109 | - if(!empty($order)){ |
|
| 109 | + if (!empty($order)) { |
|
| 110 | 110 | $arr = array_map(function(&$v, $k) { |
| 111 | 111 | return $k . ' ' . strtoupper($v); |
| 112 | 112 | }, $order, array_keys($order)); |
@@ -116,7 +116,7 @@ discard block |
||
| 116 | 116 | |
| 117 | 117 | private static function qLimit(&$q, $limit) |
| 118 | 118 | { |
| 119 | - if(!empty($limit)){ |
|
| 119 | + if (!empty($limit)) { |
|
| 120 | 120 | $l = (is_array($limit) ? implode(', ', $limit) : $limit); |
| 121 | 121 | $q .= (' LIMIT ' . $l); |
| 122 | 122 | } |
@@ -161,7 +161,7 @@ discard block |
||
| 161 | 161 | extract($vars); |
| 162 | 162 | ob_start(); |
| 163 | 163 | require $template; |
| 164 | - return (string) ob_get_clean(); |
|
| 164 | + return (string)ob_get_clean(); |
|
| 165 | 165 | } |
| 166 | 166 | /* * Makes code radey for the next table |
| 167 | 167 | * @param type $tableId |