Revert "feat(database): make email field case-insensitive"

This reverts commit 11de1be7b3.
This commit is contained in:
xboard 2025-01-16 13:53:47 +08:00
parent 5efadf87b0
commit 3b065903c2

View File

@ -1,29 +0,0 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\Facades\DB;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
DB::statement('ALTER TABLE v2_user MODIFY email VARCHAR(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci');
DB::statement('ALTER TABLE v2_user DROP INDEX email');
DB::statement('ALTER TABLE v2_user ADD UNIQUE INDEX email (email)');
}
/**
* Reverse the migrations.
*/
public function down(): void
{
DB::statement('ALTER TABLE v2_user MODIFY email VARCHAR(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci');
DB::statement('ALTER TABLE v2_user DROP INDEX email');
DB::statement('ALTER TABLE v2_user ADD UNIQUE INDEX email (email)');
}
};