allow sql fragments in Api\Storage\Base::delete as in other places

This commit is contained in:
Ralf Becker 2017-11-06 16:43:23 +01:00
parent 8fdffab564
commit 1b5e992f43

View File

@ -776,15 +776,19 @@ class Base
$data = $keys; $keys = array();
foreach($this->db_cols as $db_col => $col)
{
if (is_int($db_col))
{
$keys[] = $col;
}
elseif (isset($data[$col]))
if (isset($data[$col]))
{
$keys[$db_col] = $col;
}
}
// keep sql fragments (with integer key)
foreach($data as $key => $val)
{
if (is_int($key))
{
$keys[] = $val;
}
}
}
$data = $this->data2db($data);