Code Duplication    Length = 10-10 lines in 2 locations

system/libraries/drivers/Database/Mysql.php 1 location

@@ 252-261 (lines=10) @@
249
        return $sql;
250
    }
251
252
    public function escape_str($str)
253
    {
254
        if (!$this->db_config['escape']) {
255
            return $str;
256
        }
257
258
        is_resource($this->link) or $this->connect();
259
260
        return mysql_real_escape_string($str, $this->link);
261
    }
262
263
    public function list_tables()
264
    {

system/libraries/drivers/Database/Pgsql.php 1 location

@@ 215-224 (lines=10) @@
212
        return $sql;
213
    }
214
215
    public function escape_str($str)
216
    {
217
        if (!$this->db_config['escape']) {
218
            return $str;
219
        }
220
221
        is_resource($this->link) or $this->connect();
222
223
        return pg_escape_string($this->link, $str);
224
    }
225
226
    public function list_tables()
227
    {