fix(users): restore WeChat template notification flow
This commit is contained in:
1 parent
30ceab4615
commit
7fe26d3fff
18 files changed
+1051
-763
No files matched your search
@@ -422,6 +422,7 @@ function jio_notify_post_author_of_comment(WP_Comment $comment): void {
|
||||
'url' => get_comment_link($comment),
|
||||
]);
|
||||
update_comment_meta($comment->comment_ID, 'jio_post_comment_notified', 1);
|
||||
do_action('jio_wechat_comment_postauthor', $owner_id, $comment);
|
||||
}
|
||||
|
||||
add_action('wp_insert_comment', function ($comment_id, $comment) {
|
||||
@@ -445,6 +446,7 @@ add_action('wp_insert_comment', function ($comment_id, $comment) {
|
||||
'url' => $url ?: get_permalink($post_id),
|
||||
]);
|
||||
update_comment_meta($comment_id, 'jio_reply_notified', 1);
|
||||
do_action('jio_wechat_comment_parent', $target_user_id, $comment);
|
||||
}, 20, 2);
|
||||
|
||||
add_action('transition_comment_status', function ($new_status, $old_status, $comment) {
|
||||
@@ -478,6 +480,7 @@ add_action('transition_comment_status', function ($new_status, $old_status, $com
|
||||
'url' => get_comment_link($comment),
|
||||
]);
|
||||
update_comment_meta($comment->comment_ID, 'jio_reply_notified', 1);
|
||||
do_action('jio_wechat_comment_parent', $target_user_id, $comment);
|
||||
}, 20, 3);
|
||||
|
||||
add_action('jio_post_favorited', function (int $post_id, int $actor_id, bool $active): void {
|
||||
|
||||
Reference in new issue
Block a user