summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authormjnaderi <mjnaderi@gmail.com>2013-12-18 22:46:17 +0100
committermjnaderi <mjnaderi@gmail.com>2013-12-18 22:46:17 +0100
commit18c2e0c7d75ae91d0223bccf41d07e5a42626cd4 (patch)
tree713bb7d3d398422cc254a8b4e6e23741c0eda736 /system
parent225c37315bdaa05371cd3142dda25783f4cca8af (diff)
Cleanup DB_forge _process_indexes
Diffstat (limited to 'system')
-rw-r--r--system/database/DB_forge.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/system/database/DB_forge.php b/system/database/DB_forge.php
index bde4e2872..bec8d5554 100644
--- a/system/database/DB_forge.php
+++ b/system/database/DB_forge.php
@@ -984,6 +984,7 @@ abstract class CI_DB_forge {
*/
protected function _process_indexes($table)
{
+ $table = $this->db->escape_identifiers($table);
$sqls = array();
for ($i = 0, $c = count($this->keys); $i < $c; $i++)
@@ -1008,7 +1009,7 @@ abstract class CI_DB_forge {
is_array($this->keys[$i]) OR $this->keys[$i] = array($this->keys[$i]);
$sqls[] = 'CREATE INDEX '.$this->db->escape_identifiers(implode('_', $this->keys[$i]))
- .' ON '.$this->db->escape_identifiers($table)
+ .' ON '.$table
.' ('.implode(', ', $this->db->escape_identifiers($this->keys[$i])).');';
}