Conditions | 3 |
Paths | 4 |
Total Lines | 16 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
15 | public function up() |
||
16 | { |
||
17 | // use important column for content app |
||
18 | if (!$this->getSchema()->hasColumn('contents', 'important')) { |
||
19 | $this->getSchema()->table('contents', function ($table) { |
||
20 | $table->boolean('important')->default(false); |
||
21 | }); |
||
22 | } |
||
23 | // add group display color features |
||
24 | if (!$this->getSchema()->hasColumn('roles', 'color')) { |
||
25 | $this->getSchema()->table('roles', function ($table) { |
||
26 | $table->string('color')->default('#777777'); |
||
27 | }); |
||
28 | } |
||
29 | |||
30 | parent::up(); |
||
31 | } |
||
60 | } |
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.