diff --git a/app/Http/Controllers/SignupController.php b/app/Http/Controllers/SignupController.php index 4bb8b74..aef791d 100644 --- a/app/Http/Controllers/SignupController.php +++ b/app/Http/Controllers/SignupController.php @@ -18,7 +18,7 @@ class SignupController extends Controller "name" => "required|max:16", "username" => "required|unique:users|min:3|max:16", "email" => "required|unique:users|email|max:64", - "password" => "required|min:8|max:64", + "password" => "required|min:8|max:64|confirmed", ]); } } diff --git a/database/migrations/2024_08_20_001220_add_username_to_users_table.php b/database/migrations/2024_08_20_001220_add_username_to_users_table.php new file mode 100644 index 0000000..3495615 --- /dev/null +++ b/database/migrations/2024_08_20_001220_add_username_to_users_table.php @@ -0,0 +1,28 @@ +string("username"); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('users', function (Blueprint $table) { + $table->dropColumn("username"); + }); + } +};