Passed
Pull Request — master (#37)
by
unknown
04:18
created

CreateRolesTable   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Importance

Changes 1
Bugs 1 Features 0
Metric Value
wmc 2
eloc 5
c 1
b 1
f 0
dl 0
loc 19
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A down() 0 3 1
A up() 0 5 1
1
<?php
2
3
use Illuminate\Database\Migrations\Migration;
4
use Illuminate\Database\Schema\Blueprint;
5
use Illuminate\Support\Facades\Schema;
6
7
class CreateRolesTable extends Migration
8
{
9
    /**
10
     * Run the migrations.
11
     */
12
    public function up()
13
    {
14
        Schema::create('roles', function (Blueprint $table) {
15
            $table->increments('role_id');
16
            $table->string('name');
17
        });
18
    }
19
20
    /**
21
     * Reverse the migrations.
22
     */
23
    public function down()
24
    {
25
        Schema::drop('roles');
26
    }
27
}
28