This commit is contained in:
2025-07-03 20:40:23 +05:00
parent 8ce7bd981a
commit 251c19319a

View File

@@ -116,7 +116,7 @@ function sendSMS(string|int $phone, string|int $message)
*/
function sendSMSVerification(string|int $phone_number): ?Verification
{
$phone_code = rand(10000, 99999);
$phone_code = rand(100000, 999999);
$verification = Verification::where(['username' => $phone_number])->first();
$verification ? $verification->update(['code' => $phone_code]) : Verification::create(['username' => $phone_number, 'code' => $phone_code]);