Commit 23e36f7b authored by Dries's avatar Dries

- Patch #126867 by dmitrig01: fixed caching in presence of database prefixes.

parent d9647661
......@@ -191,12 +191,12 @@ function _db_query_callback($match, $init = FALSE) {
function db_query($query) {
$args = func_get_args();
array_shift($args);
$query = db_prefix_tables($query);
if (isset($args[0]) and is_array($args[0])) { // 'All arguments in one array' syntax
$args = $args[0];
}
_db_query_callback($args, TRUE);
$query = preg_replace_callback(DB_QUERY_REGEXP, '_db_query_callback', $query);
$query = db_prefix_tables($query);
return _db_query($query);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment