summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-01-19 14:56:20 +0100
committerAndrey Andreev <narf@bofh.bg>2012-01-19 14:56:20 +0100
commite35d7789a24e811bc147bc56c7a1d79904900b01 (patch)
treeed3f5c5e732e83b642372c3fad9ac1945d62ef92
parentb5e6f11002a08d29bd0faa2c6c5c437cf9e49523 (diff)
Some more cleaning
-rw-r--r--system/database/drivers/oci8/oci8_driver.php17
-rw-r--r--system/database/drivers/oci8/oci8_result.php3
2 files changed, 4 insertions, 16 deletions
diff --git a/system/database/drivers/oci8/oci8_driver.php b/system/database/drivers/oci8/oci8_driver.php
index 2a5149f9e..f4b899cf3 100644
--- a/system/database/drivers/oci8/oci8_driver.php
+++ b/system/database/drivers/oci8/oci8_driver.php
@@ -46,7 +46,6 @@
* permit access to oracle databases
*
* @author Kelly McArdle
- *
*/
class CI_DB_oci8_driver extends CI_DB {
@@ -249,7 +248,7 @@ class CI_DB_oci8_driver extends CI_DB {
}
// build the query string
- $sql = "BEGIN {$package}.{$procedure}(";
+ $sql = 'BEGIN '.$package.'.'.$procedure.'(';
$have_cursor = FALSE;
foreach ($params as $param)
@@ -359,13 +358,8 @@ class CI_DB_oci8_driver extends CI_DB {
*/
public function trans_rollback()
{
- if ( ! $this->trans_enabled)
- {
- return TRUE;
- }
-
// When transactions are nested we only begin/commit/rollback the outermost ones
- if ($this->_trans_depth > 0)
+ if ( ! $this->trans_enabled OR $this->_trans_depth > 0)
{
return TRUE;
}
@@ -614,12 +608,7 @@ class CI_DB_oci8_driver extends CI_DB {
*/
protected function _from_tables($tables)
{
- if ( ! is_array($tables))
- {
- $tables = array($tables);
- }
-
- return implode(', ', $tables);
+ return is_array($tables) ? implode(', ', $tables) : $tables;
}
// --------------------------------------------------------------------
diff --git a/system/database/drivers/oci8/oci8_result.php b/system/database/drivers/oci8/oci8_result.php
index e6e932175..0e0fe059d 100644
--- a/system/database/drivers/oci8/oci8_result.php
+++ b/system/database/drivers/oci8/oci8_result.php
@@ -194,7 +194,7 @@ class CI_DB_oci8_result extends CI_DB_result {
// --------------------------------------------------------------------
/**
- * Query result. "array" version.
+ * Query result. Array version.
*
* @return array
*/
@@ -516,7 +516,6 @@ class CI_DB_oci8_result extends CI_DB_result {
* @param string custom class name
* @return mixed custom object if row found; empty array otherwise
*/
-
public function custom_row_object($n = 0, $class_name)
{
// Make sure $n is not a string