Skip to content
Snippets Groups Projects
Commit 925722a8 authored by Angie Byron's avatar Angie Byron
Browse files

#850852 follow-up by Damien Tournoud: Fixed notices that caused tests to fail.

parent a87da0d7
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -622,16 +622,13 @@ public function fieldSetNoDefault($table, $field) {
}
public function findTables($table_expression) {
// Don't use getPrefixInfo -- $table_expression includes the prefix.
list($prefix, $table) = explode('.', $table_expression);
if (empty($table)) {
$table = $prefix;
$prefix = NULL;
}
// Don't add the prefix, $table_expression already includes the prefix.
$info = $this->getPrefixInfo($table_expression, FALSE);
// Can't use query placeholders because the query would have to be
// :prefixsqlite_master, which does not work.
$result = db_query("SELECT name FROM " . ($prefix ? $prefix . '.' : '') . "sqlite_master WHERE name LIKE :table_name", array(
':table_name' => $table,
$result = db_query("SELECT name FROM " . $info['schema'] . ".sqlite_master WHERE name LIKE :table_name", array(
':table_name' => $info['table'],
));
return $result->fetchAllKeyed(0, 0);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment