diff --git a/backend/auth/otp/request.php b/backend/auth/otp/request.php index d212686..f136db2 100644 --- a/backend/auth/otp/request.php +++ b/backend/auth/otp/request.php @@ -99,12 +99,12 @@ switch (strtolower($country)) { case 'syria': // Syria uses Nabeh - $sentSuccessfully = sendNabehOtp($receiver, $otp, $method, $user_type); + $sentSuccessfully = sendNabehOtp($receiver, $otp, $method ?? '', $user_type ?? 'passenger'); break; case 'jordan': // Jordan uses Nabeh - $sentSuccessfully = sendNabehOtp($receiver, $otp, $method, $user_type); + $sentSuccessfully = sendNabehOtp($receiver, $otp, $method ?? '', $user_type ?? 'passenger'); break; default: @@ -112,7 +112,7 @@ switch (strtolower($country)) { $sentSuccessfully = sendKazumiSms($receiver, $otp); if (!$sentSuccessfully) { error_log("⚠️ [Default OTP Failover] Kazumi SMS failed. Falling back to Nabeh OTP."); - $sentSuccessfully = sendNabehOtp($receiver, $otp, $method, $user_type); + $sentSuccessfully = sendNabehOtp($receiver, $otp, $method ?? '', $user_type ?? 'passenger'); } break; }