diff --git a/database/migrations/2020_04_10_141024_store_node_tokens_as_encrypted_value.php b/database/migrations/2020_04_10_141024_store_node_tokens_as_encrypted_value.php index 22c53397b..128c12ce2 100644 --- a/database/migrations/2020_04_10_141024_store_node_tokens_as_encrypted_value.php +++ b/database/migrations/2020_04_10_141024_store_node_tokens_as_encrypted_value.php @@ -23,8 +23,8 @@ class StoreNodeTokensAsEncryptedValue extends Migration }); Schema::table('nodes', function (Blueprint $table) { - $table->char('uuid', 36)->after('id')->unique(); - $table->char('daemon_token_id', 16)->after('upload_size')->unique(); + $table->char('uuid', 36)->after('id'); + $table->char('daemon_token_id', 16)->after('upload_size'); $table->renameColumn('daemonSecret', 'daemon_token'); }); @@ -45,6 +45,11 @@ class StoreNodeTokensAsEncryptedValue extends Migration ]); } }); + + Schema::table('nodes', function (Blueprint $table) { + $table->unique(['uuid']); + $table->unique(['daemon_token_id']); + }); } /**