summaryrefslogtreecommitdiffstats
path: root/system/database/DB_driver.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2013-03-21 19:33:12 +0100
committerAndrey Andreev <narf@bofh.bg>2013-03-21 19:33:12 +0100
commit5ac04e55ae968c36efac0b9c5a721936418c4e57 (patch)
tree54811e2cba6832b3901a054a318499ee656d0955 /system/database/DB_driver.php
parent13f6eabafa655828a8c09b4ae0a58a2e3776c269 (diff)
parent395e2df7ff74fe9bf4c669dea3f6ae5eb46b081e (diff)
Merge pull request #2350 from ragboyjr/develop
Making a performance modification to DB_driver list_fields()
Diffstat (limited to 'system/database/DB_driver.php')
-rw-r--r--system/database/DB_driver.php9
1 files changed, 2 insertions, 7 deletions
diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php
index 18dbbc76e..04490c824 100644
--- a/system/database/DB_driver.php
+++ b/system/database/DB_driver.php
@@ -1208,13 +1208,8 @@ abstract class CI_DB_driver {
}
else
{
- /* We have no other choice but to just get the first element's key.
- * Due to array_shift() accepting it's argument by reference, if
- * E_STRICT is on, this would trigger a warning. So we'll have to
- * assign it first.
- */
- $key = array_keys($row);
- $key = array_shift($key);
+ // We have no other choice but to just get the first element's key.
+ $key = key($row);
}
}