Total Complexity | 2 |
Total Lines | 22 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
11 | { |
||
12 | $this->createTable('notification', [ |
||
13 | 'id' => $this->primaryKey(), |
||
14 | 'level' => $this->string(), |
||
15 | 'notifiable_type' => $this->string(), |
||
16 | 'notifiable_id' => $this->integer()->unsigned(), |
||
17 | 'subject' => $this->string(), |
||
18 | 'body' => $this->text(), |
||
19 | 'read_at' => $this->timestamp()->null(), |
||
20 | 'created_at' => $this->timestamp(), |
||
21 | 'updated_at' => $this->timestamp()->null(), |
||
22 | ]); |
||
23 | $this->createIndex('notifiable', 'notification', ['notifiable_type', 'notifiable_id']); |
||
24 | } |
||
25 | |||
26 | public function down() |
||
30 | } |
||
31 | |||
32 | } |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.