Skip to content

Instantly share code, notes, and snippets.

@Brandonxy
Created September 30, 2018 22:21
Show Gist options
  • Save Brandonxy/c9ee8839074c4fe4f5bbe9fd30d1f55b to your computer and use it in GitHub Desktop.
Save Brandonxy/c9ee8839074c4fe4f5bbe9fd30d1f55b to your computer and use it in GitHub Desktop.
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddProfilePictureField extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('users', function(Blueprint $table){
$table->string('profile_picture')->default('');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('users', function(Blueprint $table){
$table->dropColumn('profile_picture');
});
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment