X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fitem.php;h=70c5c9a8b61f338d1d1d43fd75bfe2ac44b09a1e;hb=0dbb864d7db5179881c61edcb52d06be03971732;hp=cf23df8424f219ffa305df9761c2daa0851bc8e7;hpb=fba4a70dc2622097b10e44519b2c06d5e044e6ac;p=friendica.git diff --git a/mod/item.php b/mod/item.php index cf23df8424..70c5c9a8b6 100644 --- a/mod/item.php +++ b/mod/item.php @@ -221,6 +221,10 @@ function item_insert(int $uid, array $request, bool $preview, string $return_pat DI::contentItem()->postProcessPost($post, $recipients); + if (($post['private'] == Item::PRIVATE) && ($post['thr-parent-id'] != $post['uri-id'])) { + DI::contentItem()->copyPermissions($post['thr-parent-id'], $post['uri-id']); + } + Logger::debug('post_complete'); item_post_return(DI::baseUrl(), $return_path); @@ -266,6 +270,7 @@ function item_process(array $post, array $request, bool $preview, string $return $post['uri-id'] = -1; $post['author-network'] = Protocol::DFRN; $post['author-updated'] = ''; + $post['author-alias'] = ''; $post['author-gsid'] = 0; $post['author-uri-id'] = ItemURI::getIdByURI($post['author-link']); $post['owner-updated'] = ''; @@ -340,7 +345,7 @@ function item_content(App $a) $args = DI::args(); - if (!$args->has(3)) { + if (!$args->has(2)) { throw new HTTPException\BadRequestException(); }