1// 'src/Events/PostWasCreated.php'
2<?php
3
4namespace JohnDoe\BlogPackage\Events;
5
6use Illuminate\Queue\SerializesModels;
7use Illuminate\Foundation\Events\Dispatchable;
8use JohnDoe\BlogPackage\Models\Post;
9
10class PostWasCreated
11{
12 use Dispatchable, SerializesModels;
13
14 public $post;
15
16 public function __construct(Post $post)
17 {
18 $this->post = $post;
19 }
20}
21