API: photos are now directly stored as attached data and not in the body anymore

This commit is contained in:
Michael 2021-05-01 15:48:19 +00:00
commit 4b12c54345
6 changed files with 89 additions and 54 deletions

View file

@ -614,7 +614,8 @@ function item_post(App $a) {
$datarray['origin'] = $origin;
$datarray['object'] = $object;
$datarray["uri-id"] = ItemURI::getIdByURI($datarray["uri"]);
$datarray['uri-id'] = ItemURI::getIdByURI($datarray['uri']);
$datarray['attachments'] = $_REQUEST['attachments'] ?? [];
/*
* These fields are for the convenience of addons...