Commit 7cb84258 authored by alexpott's avatar alexpott

Issue #2349789 by markus_g: Fixed Responsive Image Mappings are not listed with sqlite.

parent 15cc5bd8
......@@ -269,10 +269,11 @@ public function decode($raw) {
*/
public function listAll($prefix = '') {
try {
return $this->connection->query('SELECT name FROM {' . $this->connection->escapeTable($this->table) . '} WHERE collection = :collection AND name LIKE :name', array(
':collection' => $this->collection,
':name' => $this->connection->escapeLike($prefix) . '%',
), $this->options)->fetchCol();
$query = $this->connection->select($this->table);
$query->fields($this->table, array('name'));
$query->condition('collection', $this->collection, '=');
$query->condition('name', $prefix . '%', 'LIKE');
return $query->execute()->fetchCol();
}
catch (\Exception $e) {
return array();
......
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