summaryrefslogtreecommitdiff
path: root/it_dbi.class
diff options
context:
space:
mode:
authorChristian Schneider2008-04-01 15:24:40 +0000
committerChristian Schneider2008-04-01 15:24:40 +0000
commit4a448100a65bac8d8fd4b1816227e5de5290f50d (patch)
tree6637caa9c3af02cf1b72c9ab0f6b392fc67d6394 /it_dbi.class
parent479528efc0dafcf0dd57a48dc8d9dd1a270827b8 (diff)
downloaditools-4a448100a65bac8d8fd4b1816227e5de5290f50d.tar.gz
itools-4a448100a65bac8d8fd4b1816227e5de5290f50d.tar.bz2
itools-4a448100a65bac8d8fd4b1816227e5de5290f50d.zip
Fix warning about get_func_args() used as parameter to other function
Diffstat (limited to 'it_dbi.class')
-rw-r--r--it_dbi.class9
1 files changed, 7 insertions, 2 deletions
diff --git a/it_dbi.class b/it_dbi.class
index e59bdc2..4c4b291 100644
--- a/it_dbi.class
+++ b/it_dbi.class
@@ -78,8 +78,13 @@ function it_dbi($p = array(), $query = null)
if ($p['getfieldinfo'])
$this->_p += $this->_get_field_info(); # Get $this->_fields and p[keyfield, autoincrement, randomid]
- if (is_array($query)) # Call with all arguments except first one
- call_user_func_array(array($this, "select"), array(0 => null) + func_get_args());
+ if (is_array($query))
+ {
+ # Call with all arguments except first one
+ $args = func_get_args();
+ array_shift($args);
+ call_user_func_array(array($this, "select"), $args);
+ }
elseif (isset($query))
$this->read($query);
}