From c62c7deae0587f7a8341ffc7bde8358dfc564092 Mon Sep 17 00:00:00 2001 From: sicommnend Date: Wed, 14 Sep 2016 15:35:38 -0600 Subject: [PATCH] Check pre-query Check pre query to prevent duplicate listings. Signed-off-by: sicommnend <> --- install.xml | 10 +++++----- package-info.xml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/install.xml b/install.xml index 943d47a..a6e3f01 100644 --- a/install.xml +++ b/install.xml @@ -2,7 +2,7 @@ NEND:clonetopic - 0.4.3 + 0.4.5 array('Who.php', 'Credits'), @@ -123,8 +123,8 @@ $txt['permissionname_simple_clone_any'] = 'Clone anyone\'s topic'; WHERE t.id_board = {int:current_board}' . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : ' AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . ']]> + '.($clone_topics ? 'OR t.id_topic IN ({array_int:clone_topics})'.(!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : ' + AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') : '' ) .']]> + '.($clone_topics && !$pre_query ? 'OR t.id_topic IN ({array_int:clone_topics})'.(!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : ' + AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') : '' ) .']]> NEND:clonetopic Clone Topic - 0.4.3 + 0.4.5 modification db.php