From c23a71c936e5ad73830c7a1ca7533e797f3c382f Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Sat, 12 Oct 2024 17:05:35 +0200 Subject: code consistency --- include/items.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/items.php b/include/items.php index bb14cfb73..16522b0a6 100644 --- a/include/items.php +++ b/include/items.php @@ -3397,12 +3397,13 @@ function start_delivery_chain($channel, $item, $item_id, $parent, $group = false $arr['comment_policy'] = map_scope(PermissionLimits::Get($channel['channel_id'],'post_comments')); $post = item_store($arr, deliver: false, addAndSync: false); - $post_id = $post['item_id']; + $post_id = $post['item_id'] ?? 0; + $approval_id = $post['approval_id'] ?? 0; if ($post_id) { Master::Summon([ 'Notifier','tgroup',$post_id ]); - if (!empty($post['approval_id'])) { - Master::Summon(['Notifier', 'tgroup', $post['approval_id']]); + if ($approval_id) { + Master::Summon(['Notifier', 'tgroup', $approval_id]); } } -- cgit v1.2.3