@@ -53,10 +53,11 @@ discard block |
||
53 | 53 | $hs->select($idx, $operator, $condition); |
54 | 54 | $result = $hs->readResponse(); |
55 | 55 | |
56 | - if (!empty($result)) |
|
57 | - return $result[0]; |
|
58 | - else |
|
59 | - return FALSE; |
|
56 | + if (!empty($result)) { |
|
57 | + return $result[0]; |
|
58 | + } else { |
|
59 | + return FALSE; |
|
60 | + } |
|
60 | 61 | } |
61 | 62 | |
62 | 63 | public function fetchAll($table, Array $fields, $index, Array $condition, $operator, $limit, $offset) |
@@ -78,9 +79,9 @@ discard block |
||
78 | 79 | } |
79 | 80 | |
80 | 81 | return $result; |
82 | + } else { |
|
83 | + return FALSE; |
|
81 | 84 | } |
82 | - else |
|
83 | - return FALSE; |
|
84 | 85 | } |
85 | 86 | |
86 | 87 | public function delete($table, $index, Array $condition, $operator) |
@@ -93,10 +94,11 @@ discard block |
||
93 | 94 | $hs->delete($idx, $operator, $condition); |
94 | 95 | $result = $hs->readResponse(); |
95 | 96 | |
96 | - if (!empty($result)) |
|
97 | - return (bool)$result[0][0]; |
|
98 | - else |
|
99 | - return FALSE; |
|
97 | + if (!empty($result)) { |
|
98 | + return (bool)$result[0][0]; |
|
99 | + } else { |
|
100 | + return FALSE; |
|
101 | + } |
|
100 | 102 | } |
101 | 103 | |
102 | 104 | public function insert($table, Array $values) |
@@ -128,10 +130,11 @@ discard block |
||
128 | 130 | |
129 | 131 | $result = $hs->readResponse(); |
130 | 132 | |
131 | - if (!empty($result)) |
|
132 | - return (bool)$result[0][0]; |
|
133 | - else |
|
134 | - return FALSE; |
|
133 | + if (!empty($result)) { |
|
134 | + return (bool)$result[0][0]; |
|
135 | + } else { |
|
136 | + return FALSE; |
|
137 | + } |
|
135 | 138 | } |
136 | 139 | |
137 | 140 | public function increment($table, $field, $index, Array $condition, $operator, $increment) |
@@ -144,10 +147,11 @@ discard block |
||
144 | 147 | $hs->increment($idx, $operator, $condition, [$increment]); |
145 | 148 | $result = $hs->readResponse(); |
146 | 149 | |
147 | - if (!empty($result)) |
|
148 | - return (bool)$result[0][0]; |
|
149 | - else |
|
150 | - return FALSE; |
|
150 | + if (!empty($result)) { |
|
151 | + return (bool)$result[0][0]; |
|
152 | + } else { |
|
153 | + return FALSE; |
|
154 | + } |
|
151 | 155 | } |
152 | 156 | |
153 | 157 | public function decrement($table, $field, $index, Array $condition, $operator, $decrement) |
@@ -160,9 +164,10 @@ discard block |
||
160 | 164 | $hs->decrement($idx, $operator, $condition, [$decrement]); |
161 | 165 | $result = $hs->readResponse(); |
162 | 166 | |
163 | - if (!empty($result)) |
|
164 | - return (bool)$result[0][0]; |
|
165 | - else |
|
166 | - return FALSE; |
|
167 | + if (!empty($result)) { |
|
168 | + return (bool)$result[0][0]; |
|
169 | + } else { |
|
170 | + return FALSE; |
|
171 | + } |
|
167 | 172 | } |
168 | 173 | } |
169 | 174 | \ No newline at end of file |