mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-09 12:02:24 +09:00
Fix login error when the user enters a phone number containing hyphens or other symbols
This commit is contained in:
parent
90d3766e5c
commit
246a952cf6
1 changed files with 3 additions and 3 deletions
|
|
@ -2218,10 +2218,10 @@ class memberController extends member
|
||||||
$phone_country = Rhymix\Framework\i18n::getCountryCodeByCallingCode($phone_country);
|
$phone_country = Rhymix\Framework\i18n::getCountryCodeByCallingCode($phone_country);
|
||||||
}
|
}
|
||||||
|
|
||||||
$user_phone_number_id = preg_replace('/[^0-9]/', '', $user_id);
|
$numbers_only = preg_replace('/[^0-9]/', '', $user_id);
|
||||||
$member_info = MemberModel::getMemberInfoByPhoneNumber($user_phone_number_id, $phone_country);
|
$member_info = MemberModel::getMemberInfoByPhoneNumber($numbers_only, $phone_country);
|
||||||
$used_identifier = 'phone_number';
|
$used_identifier = 'phone_number';
|
||||||
if(!$member_info || strtolower($member_info->phone_number) !== $user_id)
|
if(!$member_info || preg_replace('/[^0-9]/', '', $member_info->phone_number) !== $numbers_only)
|
||||||
{
|
{
|
||||||
if(in_array('user_id', $config->identifiers))
|
if(in_array('user_id', $config->identifiers))
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue