Add unique key to token name

This commit is contained in:
Daniel_I_Am 2020-08-29 14:16:27 +02:00
parent 4d2d3cb96f
commit bc44418152
No known key found for this signature in database
GPG Key ID: 80C428FCC9743E84

View File

@ -15,7 +15,7 @@ class CreateAuthTokensTable extends Migration
{ {
Schema::create('auth_tokens', function (Blueprint $table) { Schema::create('auth_tokens', function (Blueprint $table) {
$table->id(); $table->id();
$table->string('name', 255); $table->string('name', 255)->unique();
$table->string('token', 255)->unique(); $table->string('token', 255)->unique();
}); });
} }