AllowNullReleaseSize::down()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 8
rs 9.4286
cc 1
eloc 4
nc 1
nop 0
1
<?php
2
3
namespace CosmicRadioTV\Podcast\Updates;
4
5
use DB;
6
use Illuminate\Database\Schema\Blueprint;
7
use October\Rain\Database\Updates\Migration;
8
use Schema;
9
10
class AllowNullReleaseSize extends Migration
11
{
12
13
    /**
14
     * Migration
15
     */
16
    public function up()
17
    {
18
        DB::transaction(function () {
19
            Schema::table('cosmicradiotv_podcast_releases', function (Blueprint $table) {
20
                $table->bigInteger('size')->nullable()->change();
21
            });
22
        });
23
    }
24
25
    /**
26
     * Rollback
27
     */
28
    public function down()
29
    {
30
        DB::transaction(function () {
31
            Schema::table('cosmicradiotv_podcast_releases', function (Blueprint $table) {
32
                $table->bigInteger('size')->change();
33
            });
34
        });
35
    }
36
}