protected function StringDatabaseStorage::dbDelete in Localization update 7.2
Creates delete query.
Parameters
string $table: The table name.
array $keys: Array with object keys indexed by field name.
Return value
DeleteQuery Returns a new DeleteQuery object for the active database.
File
- includes/
locale/ StringDatabaseStorage.php, line 497 - Definition of StringDatabaseStorage.
Class
- StringDatabaseStorage
- Defines the locale string class.
Code
protected function dbDelete($table, array $keys) {
$query = db_delete($table, $this->options);
// Change field 'customized' into 'l10n_status'. This enables the Drupal 8
// backported code to work with the Drupal 7 style database tables.
if (isset($keys['customized'])) {
$keys['l10n_status'] = $keys['customized'];
unset($keys['customized']);
}
foreach ($keys as $field => $value) {
$query
->condition($field, $value);
}
return $query;
}