Fix for query with empty ID

This commit is contained in:
Eldad Fux 2020-03-08 21:25:31 +02:00
parent 5eedfdd3fe
commit 01552bb13b

View file

@ -156,6 +156,7 @@ class MySQL extends Adapter
$data = array_merge(['$id' => null, '$permissions' => []], $data); // Merge data with default params
$signature = md5(json_encode($data, true));
$revision = uniqid('', true);
$data['$id'] = (empty($data['$id'])) ? null : $data['$id'];
/*
* When updating node, check if there are any changes to update