$userData = CUser::GetByID($arFields['ID'])->Fetch();
$checkOldPassword = Bitrix\Main\Security\Password::equals($userData['PASSWORD'], $_REQUEST['OLD_PASSWORD']);
if (!$checkOldPassword) {
$APPLICATION->ThrowException(GetMessage("ERROR_OLD_PASSWORD"));
return false;
}
$checkOldPassword = Bitrix\Main\Security\Password::equals($userData['PASSWORD'], $_REQUEST['OLD_PASSWORD']);
if (!$checkOldPassword) {
$APPLICATION->ThrowException(GetMessage("ERROR_OLD_PASSWORD"));
return false;
}