summaryrefslogtreecommitdiffstats
path: root/system/database
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2015-04-06 23:02:14 +0200
committerAndrey Andreev <narf@devilix.net>2015-04-06 23:02:14 +0200
commit19311361d52413746327b590e3ef51e4d718fd82 (patch)
treed36853619969ecbe4aa403a37e34ec7c87f7b357 /system/database
parent7726b75552f765af94038e47a4a4272ac08c646e (diff)
Move strtolower() call from PR #3739 out of the loop
Diffstat (limited to 'system/database')
-rw-r--r--system/database/DB_query_builder.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/system/database/DB_query_builder.php b/system/database/DB_query_builder.php
index a77ed57d0..5005d0163 100644
--- a/system/database/DB_query_builder.php
+++ b/system/database/DB_query_builder.php
@@ -918,6 +918,8 @@ abstract class CI_DB_query_builder extends CI_DB_driver {
}
is_bool($escape) OR $escape = $this->_protect_identifiers;
+ // lowercase $side in case somebody writes e.g. 'BEFORE' instead of 'before' (doh)
+ $side = strtolower($side);
foreach ($field as $k => $v)
{
@@ -925,9 +927,6 @@ abstract class CI_DB_query_builder extends CI_DB_driver {
? $this->_group_get_type('') : $this->_group_get_type($type);
$v = $this->escape_like_str($v);
-
- // lowercase $side for in case of UPPERCASE string
- $side = strtolower($side);
if ($side === 'none')
{