Passed
Pull Request — master (#1)
by Gombos
01:47
created

CreateModelSettingsTable::up()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 6
nc 1
nop 0
dl 0
loc 8
rs 10
c 1
b 0
f 0
1
<?php
2
3
use Illuminate\Database\Migrations\Migration;
4
use Illuminate\Database\Schema\Blueprint;
0 ignored issues
show
Bug introduced by
The type Illuminate\Database\Schema\Blueprint was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
5
use Illuminate\Support\Facades\Schema;
6
7
class CreateModelSettingsTable extends Migration
8
{
9
    public function up()
10
    {
11
        Schema::create('model_settings', function (Blueprint $table) {
12
            $table->increments('id');
13
            $table->bigInteger('model_id');
14
            $table->string('model_type');
15
            $table->json('settings');
16
            $table->timestamps();
17
        });
18
    }
19
20
    public function down()
21
    {
22
        Schema::dropIfExists('model_settings');
23
    }
24
}
25