Skip to content

Commit

Permalink
Make the user_id column big integer (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
chrysanthos committed Oct 27, 2022
1 parent 66eccec commit 62975b4
Showing 1 changed file with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,9 @@ public function up()
static function (Blueprint $table) {
$table->bigIncrements('id');

$table->unsignedInteger('user_id');
$table->foreign('user_id')
->references('id')
->on(config('password-history.tables.users.name', 'users'))
->onDelete('cascade');
$table->foreignId('user_id')
->constrained(config('password-history.tables.users.name', 'users'))
->cascadeOnDelete();

$table->string('password');

Expand Down

0 comments on commit 62975b4

Please sign in to comment.