forked from D3Public/oxtotp
remove warning issues
This commit is contained in:
parent
3f77b212b4
commit
337107fe52
@ -17,7 +17,6 @@ use BaconQrCode\Renderer\RendererInterface;
|
||||
use BaconQrCode\Writer;
|
||||
use D3\Totp\Application\Factory\BaconQrCodeFactory;
|
||||
use D3\Totp\Application\Model\Exceptions\d3totp_wrongOtpException;
|
||||
use Doctrine\DBAL\DBALException;
|
||||
use OTPHP\TOTP;
|
||||
use OxidEsales\Eshop\Application\Model\User;
|
||||
use OxidEsales\Eshop\Core\Database\Adapter\DatabaseInterface;
|
||||
@ -89,7 +88,7 @@ class d3totp extends BaseModel
|
||||
*/
|
||||
public function getUser()
|
||||
{
|
||||
$userId = $this->userId ? $this->userId : $this->getFieldData('oxuserid');
|
||||
$userId = $this->userId ?: $this->getFieldData('oxuserid');
|
||||
|
||||
$user = $this->d3GetUser();
|
||||
$user->load($userId);
|
||||
|
@ -10,7 +10,7 @@
|
||||
[{assign var="readonly" value=""}]
|
||||
[{/if}]
|
||||
|
||||
<style type="text/css">
|
||||
<style>
|
||||
td.edittext {
|
||||
white-space: normal;
|
||||
}
|
||||
|
@ -6,7 +6,7 @@
|
||||
[{assign var="userid" value=$user->getId()}]
|
||||
[{$totp->loadByUserId($userid)}]
|
||||
|
||||
<style type="text/css">
|
||||
<style>
|
||||
.registerNew {
|
||||
display: none;
|
||||
}
|
||||
|
@ -38,18 +38,16 @@ use OxidEsales\Eshop\Application\Model as OxidModel;
|
||||
$sMetadataVersion = '2.0';
|
||||
|
||||
$sModuleId = 'd3totp';
|
||||
$logo = '<img src="https://logos.oxidmodule.com/d3logo.svg" alt="(D3)" style="height:1em;width:1em">';
|
||||
|
||||
/**
|
||||
* Module information
|
||||
*/
|
||||
$aModule = [
|
||||
'id' => $sModuleId,
|
||||
'title' => [
|
||||
'de' =>
|
||||
'<svg style="height:1em;width:1em"><image xlink:href="https://logos.oxidmodule.com/d3logo.svg" style="height:1em;width:1em" /></svg> '.
|
||||
'Zwei-Faktor-Authentisierung',
|
||||
'en' =>
|
||||
'<svg style="height:1em;width:1em"><image xlink:href="https://logos.oxidmodule.com/d3logo.svg" style="height:1em;width:1em" /></svg> '.
|
||||
'two-factor authentication',
|
||||
'de' => $logo . 'Zwei-Faktor-Authentisierung',
|
||||
'en' => $logo . 'two-factor authentication',
|
||||
],
|
||||
'description' => [
|
||||
'de' => 'Zwei-Faktor-Authentisierung (TOTP) für OXID eSales Shop',
|
||||
|
@ -30,14 +30,14 @@ class d3_account_totpTest extends d3TotpUnitTestCase
|
||||
/**
|
||||
* setup basic requirements
|
||||
*/
|
||||
public function setUp()
|
||||
public function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
$this->_oController = oxNew(d3_account_totp::class);
|
||||
}
|
||||
|
||||
public function tearDown()
|
||||
public function tearDown(): void
|
||||
{
|
||||
parent::tearDown();
|
||||
|
||||
|
@ -33,14 +33,14 @@ class d3_totp_LoginControllerTest extends d3TotpUnitTestCase
|
||||
/**
|
||||
* setup basic requirements
|
||||
*/
|
||||
public function setUp()
|
||||
public function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
$this->_oController = oxNew(d3_totp_LoginController::class);
|
||||
}
|
||||
|
||||
public function tearDown()
|
||||
public function tearDown(): void
|
||||
{
|
||||
parent::tearDown();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user