prevent type error

This commit is contained in:
Daniel Seifert 2022-11-14 09:07:34 +01:00
parent 4edfa2d3c3
commit d7912f6371
Signed by: DanielS
GPG Key ID: 8A7C4C6ED1915C6F
4 changed files with 2 additions and 5 deletions

View File

@ -147,7 +147,7 @@ class d3totpadminlogin extends AdminController
$userId = $user->d3TotpGetCurrentUser();
try {
$sTotp = implode('', Registry::getRequest()->getRequestEscapedParameter('d3totp'));
$sTotp = implode('', Registry::getRequest()->getRequestEscapedParameter('d3totp', []));
$totp = $this->d3TotpGetTotpObject();
$totp->loadByUserId($userId);

View File

@ -84,7 +84,7 @@ class d3_totp_UserComponent extends d3_totp_UserComponent_parent
*/
public function d3TotpCheckTotpLogin()
{
$sTotp = implode('', Registry::getRequest()->getRequestEscapedParameter('d3totp'));
$sTotp = implode('', Registry::getRequest()->getRequestEscapedParameter('d3totp', []));
/** @var d3_totp_user $oUser */
$oUser = oxNew(User::class);

View File

@ -13,7 +13,6 @@
namespace D3\Totp\tests\unit\Modules\Application\Controller\Admin;
use D3\TestingTools\Development\IsMockable;
use D3\TestingTools\Development\CanAccessRestricted;
use D3\Totp\Application\Model\d3totp;
use D3\Totp\Application\Model\d3totp_conf;
@ -28,7 +27,6 @@ use ReflectionException;
class d3_totp_LoginControllerTest extends d3TotpUnitTestCase
{
use CanAccessRestricted;
use IsMockable;
/** @var d3_totp_LoginController */
protected $_oController;

View File

@ -13,7 +13,6 @@
namespace D3\Totp\tests\unit\Modules\Application\Controller;
use D3\TestingTools\Development\IsMockable;
use D3\TestingTools\Development\CanAccessRestricted;
use D3\Totp\Application\Model\d3totp;
use D3\Totp\Modules\Application\Controller\d3_totp_OrderController;