aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_posting.php
diff options
context:
space:
mode:
author3Di <three3di@hotmail.it>2018-10-26 18:33:30 +0200
committerGitHub <noreply@github.com>2018-10-26 18:33:30 +0200
commit379900b4eda527d91c2e3252db5e3b89038bc425 (patch)
tree6c8db1854d475b2b15c1b5c98c77e5f9f9fa1ff3 /phpBB/includes/functions_posting.php
parent001f32da95d4f8697ccc9a6107afc8dc68cbe48e (diff)
parentfd95355c6129043e09d189c193ff5d1abde8db96 (diff)
downloadforums-379900b4eda527d91c2e3252db5e3b89038bc425.tar
forums-379900b4eda527d91c2e3252db5e3b89038bc425.tar.gz
forums-379900b4eda527d91c2e3252db5e3b89038bc425.tar.bz2
forums-379900b4eda527d91c2e3252db5e3b89038bc425.tar.xz
forums-379900b4eda527d91c2e3252db5e3b89038bc425.zip
Merge pull request #2 from phpbb/3.2.x
3.2.x
Diffstat (limited to 'phpBB/includes/functions_posting.php')
-rw-r--r--phpBB/includes/functions_posting.php21
1 files changed, 20 insertions, 1 deletions
diff --git a/phpBB/includes/functions_posting.php b/phpBB/includes/functions_posting.php
index 78c66ac6b8..1e8f1ad00d 100644
--- a/phpBB/includes/functions_posting.php
+++ b/phpBB/includes/functions_posting.php
@@ -2282,6 +2282,19 @@ function submit_post($mode, $subject, $username, $topic_type, &$poll_ary, &$data
'post_subject' => $subject,
));
+ /**
+ * This event allows you to modify the notification data upon submission
+ *
+ * @event core.modify_submit_notification_data
+ * @var array notification_data The notification data to be inserted in to the database
+ * @var array data_ary The data array with a lot of the post submission data
+ * @var string mode The posting mode
+ * @var int poster_id The poster id
+ * @since 3.2.4-RC1
+ */
+ $vars = array('notification_data', 'data_ary', 'mode', 'poster_id');
+ extract($phpbb_dispatcher->trigger_event('core.modify_submit_notification_data', compact($vars)));
+
/* @var $phpbb_notifications \phpbb\notification\manager */
$phpbb_notifications = $phpbb_container->get('notification_manager');
@@ -2309,8 +2322,14 @@ function submit_post($mode, $subject, $username, $topic_type, &$poll_ary, &$data
case 'edit_first_post':
case 'edit':
case 'edit_last_post':
+ if ($user->data['user_id'] == $poster_id)
+ {
+ $phpbb_notifications->update_notifications(array(
+ 'notification.type.quote',
+ ), $notification_data);
+ }
+
$phpbb_notifications->update_notifications(array(
- 'notification.type.quote',
'notification.type.bookmark',
'notification.type.topic',
'notification.type.post',