diff options
author | Andrey Andreev <narf@bofh.bg> | 2013-03-01 15:28:58 +0100 |
---|---|---|
committer | Andrey Andreev <narf@bofh.bg> | 2013-03-01 15:28:58 +0100 |
commit | d327c797027d4ccf3bb624d7f4edd10997e372ac (patch) | |
tree | c138a038abb0986890132b07d8ffd20e4118a453 /system/database/DB_utility.php | |
parent | 6c463e162c37963312f51993b1ae5281b2643546 (diff) |
Optimize changes from PR #2290
Diffstat (limited to 'system/database/DB_utility.php')
-rw-r--r-- | system/database/DB_utility.php | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/system/database/DB_utility.php b/system/database/DB_utility.php index b270cdd4d..9f953d4ac 100644 --- a/system/database/DB_utility.php +++ b/system/database/DB_utility.php @@ -238,8 +238,7 @@ abstract class CI_DB_utility { $out .= $enclosure.str_replace($enclosure, $enclosure.$enclosure, $name).$enclosure.$delim; } - $out = substr(rtrim($out), 0, -strlen($delim)); // Remove the trailing delimiter character(s) at the end of the column names - $out = $out.$newline; + $out = substr(rtrim($out), 0, -strlen($delim)).$newline; // Next blast through the result array and build out the rows while ($row = $query->unbuffered_row('array')) @@ -248,8 +247,7 @@ abstract class CI_DB_utility { { $out .= $enclosure.str_replace($enclosure, $enclosure.$enclosure, $item).$enclosure.$delim; } - $out = substr(rtrim($out), 0, -strlen($delim)); // Remove the trailing delimiter character(s) at the end of the row lines - $out = rtrim($out).$newline; + $out = substr(rtrim($out), 0, -strlen($delim)).$newline; } return $out; |