<commit_before><?php

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

class CreateAddressesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('addresses', function (Blueprint $table) {
            $table->increments('id');
            $table->unsignedInteger('user_id');
            $table->string('addressee', 50)->nullable();
            $table->string('organization', 50)->nullable();
            $table->string('line_1', 50);
            $table->string('line_2', 50)->nullable();
            $table->string('city', 50);
            $table->unsignedInteger('state_id');
            $table->string('zip', 11);
            $table->unsignedInteger('country_id');
            $table->float('latitude')->nullable();
            $table->float('longitude')->nullable();
            $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
            $table->foreign('state_id')->references('id')->on('states')->onDelete('cascade');
            $table->foreign('country_id')->references('id')->on('countries')->onDelete('cascade');
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('addresses', function (Blueprint $table) {
            $table->dropForeign('addresses_user_id_foreign');
            $table->dropForeign('addresses_state_id_foreign');
            $table->dropForeign('addresses_country_id_foreign');
        });

        Schema::drop('address');
    }
}<commit_msg>added country->sate->address models, and controller methods. Started docs on country and state<commit_after><?php

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

class CreateAddressesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('addresses', function (Blueprint $table) {
            $table->increments('id');
            $table->unsignedInteger('user_id');
            $table->string('addressee', 50)->nullable();
            $table->string('organization', 50)->nullable();
            $table->string('line_1', 50);
            $table->string('line_2', 50)->nullable();
            $table->string('city', 50);
            $table->unsignedInteger('state_id');
            $table->string('zip', 11);
            $table->unsignedInteger('country_id');
            $table->float('latitude')->nullable();
            $table->float('longitude')->nullable();
            $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
            $table->foreign('state_id')->references('id')->on('states')->onDelete('cascade');
            $table->foreign('country_id')->references('id')->on('countries')->onDelete('cascade');
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('addresses', function (Blueprint $table) {
            $table->dropForeign('addresses_user_id_foreign');
            $table->dropForeign('addresses_state_id_foreign');
            $table->dropForeign('addresses_country_id_foreign');
        });

        Schema::drop('addresses');
    }
}
{'fraction_non_alphanumeric': 0.1805183199285076, 'fraction_numerical': 0.008340780458742925, 'mean_word_length': 2.6460369163952224, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 69, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7391182', 'n_tokens_mistral': 950, 'n_tokens_neox': 925, 'n_words': 127}