aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/mcp
diff options
context:
space:
mode:
authorMarc Alexander <admin@m-a-styles.de>2016-12-11 15:59:08 +0100
committerMarc Alexander <admin@m-a-styles.de>2016-12-11 15:59:08 +0100
commitdbd003a0d1ca66d9934ea896710082ffbd41691f (patch)
tree04853f9f688d0d12f2e2634cf7a436023f7c77cc /phpBB/includes/mcp
parent04e68c092b6394ccdcec2d89551ace63529a14ba (diff)
parent96adf7f0d69a48b3437e751ae99c26326882a3f4 (diff)
downloadforums-dbd003a0d1ca66d9934ea896710082ffbd41691f.tar
forums-dbd003a0d1ca66d9934ea896710082ffbd41691f.tar.gz
forums-dbd003a0d1ca66d9934ea896710082ffbd41691f.tar.bz2
forums-dbd003a0d1ca66d9934ea896710082ffbd41691f.tar.xz
forums-dbd003a0d1ca66d9934ea896710082ffbd41691f.zip
Merge branch '3.1.x' into 3.2.x
Diffstat (limited to 'phpBB/includes/mcp')
-rw-r--r--phpBB/includes/mcp/mcp_main.php14
1 files changed, 13 insertions, 1 deletions
diff --git a/phpBB/includes/mcp/mcp_main.php b/phpBB/includes/mcp/mcp_main.php
index 3f83d99a0f..5786aa343a 100644
--- a/phpBB/includes/mcp/mcp_main.php
+++ b/phpBB/includes/mcp/mcp_main.php
@@ -470,7 +470,7 @@ function change_topic_type($action, $topic_ids)
*/
function mcp_move_topic($topic_ids)
{
- global $auth, $user, $db, $template, $phpbb_log, $request;
+ global $auth, $user, $db, $template, $phpbb_log, $request, $phpbb_dispatcher;
global $phpEx, $phpbb_root_path;
// Here we limit the operation to one forum only
@@ -632,6 +632,18 @@ function mcp_move_topic($topic_ids)
'poll_last_vote' => (int) $row['poll_last_vote']
);
+ /**
+ * Perform actions before shadow topic is created.
+ *
+ * @event core.mcp_main_modify_shadow_sql
+ * @var array shadow SQL array to be used by $db->sql_build_array
+ * @since 3.1.11-RC1
+ */
+ $vars = array(
+ 'shadow',
+ );
+ extract($phpbb_dispatcher->trigger_event('core.mcp_main_modify_shadow_sql', compact($vars)));
+
$db->sql_query('INSERT INTO ' . TOPICS_TABLE . $db->sql_build_array('INSERT', $shadow));
// Shadow topics only count on new "topics" and not posts... a shadow topic alone has 0 posts