summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorSoesapto Joeni Hantoro <shidec00@yahoo.com>2012-05-15 11:37:46 +0200
committerSoesapto Joeni Hantoro <shidec00@yahoo.com>2012-05-15 11:37:46 +0200
commitdabeaa11ca2076935e5091e0f9e90ff9c4593962 (patch)
treefbbbac248170840b04767386051d2d4b1c7645ea /system
parent5963db71348a06c14b38e7ce998df4249d4fd45a (diff)
Escaping boolean data type for postgre
Diffstat (limited to 'system')
-rw-r--r--system/database/drivers/postgre/postgre_driver.php12
1 files changed, 2 insertions, 10 deletions
diff --git a/system/database/drivers/postgre/postgre_driver.php b/system/database/drivers/postgre/postgre_driver.php
index 4b2fb7a9e..670eb549d 100644
--- a/system/database/drivers/postgre/postgre_driver.php
+++ b/system/database/drivers/postgre/postgre_driver.php
@@ -321,20 +321,12 @@ class CI_DB_postgre_driver extends CI_DB {
*/
public function escape($str)
{
- if (is_string($str) OR method_exists($str, '__toString'))
- {
- return "'".$this->escape_str($str)."'";
- }
- elseif (is_bool($str))
+ if (is_bool($str))
{
return ($str) ? 'TRUE' : 'FALSE';
}
- elseif (is_null($str))
- {
- return 'NULL';
- }
- return $str;
+ return parent::escape($str);
}
// --------------------------------------------------------------------