Skip to content

Commit 1e3ea05

Browse files
committed
Fix PHP warning when last topic post requires approval
1 parent c185082 commit 1e3ea05

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

event/listener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,6 @@ public function posts_merging($event)
169169
)
170170
{
171171
$merge_post_data = $this->helper->get_last_post_data($data);
172-
$post_visibility = $merge_post_data['post_visibility'];
173172

174173
// Do not merge if there's no last post data, the poster is not current user, user is not registered,or
175174
// the post is locked, has not yet been approved or allowed merge period has left
@@ -197,6 +196,7 @@ public function posts_merging($event)
197196

198197
$data['post_id'] = (int) $merge_post_data['post_id'];
199198
$merge_post_data['post_attachment'] = ($total_attachments_count) ? 1 : 0;
199+
$post_visibility = $merge_post_data['post_visibility'];
200200

201201
// Decode old message and addon
202202
$merge_post_data['post_text'] = $this->helper->prepare_text_for_merge($merge_post_data);

0 commit comments

Comments
 (0)