FluxBB\Handlers\UpdateForumStats::whenUserHasPosted PHP Метод

whenUserHasPosted() публичный Метод

public whenUserHasPosted ( UserHasPosted $event )
$event FluxBB\Events\UserHasPosted
    public function whenUserHasPosted(UserHasPosted $event)
    {
        $post = $event->post;
        $topic = $post->topic;
        $topic->last_post_id = $post->id;
        $topic->num_replies += 1;
        $topic->save();
        $forum = $topic->forum;
        $forum->num_posts += 1;
        $forum->last_post = $topic->last_post;
        $forum->last_post_id = $topic->last_post_id;
        $forum->last_poster = $topic->last_poster;
        $forum->save();
    }
UpdateForumStats