GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

CreateRatingTable::up()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 10
Code Lines 8

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 8
dl 0
loc 10
rs 10
c 1
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
use Illuminate\Database\Migrations\Migration;
4
use Illuminate\Database\Schema\Blueprint;
5
use Illuminate\Support\Facades\Schema;
6
7
class CreateRatingTable extends Migration
8
{
9
    /**
10
     * Run the migrations.
11
     */
12
    public function up()
13
    {
14
        Schema::create(config('rating.table_name', 'ratings'), function (Blueprint $table) {
15
            $table->increments('id');
16
            $table->string('rater_type')->nullable();
17
            $table->integer('rater_id')->nullable();
18
            $table->string('rateable_type');
19
            $table->string('rateable_id');
20
            $table->float('rating', 9, 2);
21
            $table->timestamps();
22
        });
23
    }
24
25
    /**
26
     * Reverse the migrations.
27
     */
28
    public function down()
29
    {
30
        Schema::dropIfExists(config('rating.table_name', 'ratings'));
31
    }
32
}
33