<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;

class Update1560773179DevelopersTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('developers', function (Blueprint $table) {
            if (!Schema::hasColumn('developers', 'banner')) {
                $table->string('banner')->nullable();
            }
            if (!Schema::hasColumn('developers', 'logotype_color')) {
                $table->string('logotype_color')->nullable();
            }
            if (!Schema::hasColumn('developers', 'logotype_path_hidden')) {
                $table->string('logotype_path_hidden')->nullable();
            }
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('developers', function (Blueprint $table) {
            $table->dropColumn('banner');
            $table->dropColumn('logotype_color');
            $table->dropColumn('logotype_path_hidden');
        });
    }
}
