d8b3fe460e
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
19 lines
438 B
PHP
19 lines
438 B
PHP
<?php
|
|
|
|
use OCA\TwoFactorBackupCodes\Provider\BackupCodesProvider;
|
|
use OCP\Template;
|
|
|
|
// @codeCoverageIgnoreStart
|
|
|
|
/* @var $provider BackupCodesProvider */
|
|
$provider = OC::$server->query(BackupCodesProvider::class);
|
|
$user = OC::$server->getUserSession()->getUser();
|
|
|
|
if ($provider->isActive($user)) {
|
|
$tmpl = new Template('twofactor_backupcodes', 'personal');
|
|
return $tmpl->fetchPage();
|
|
} else {
|
|
return "";
|
|
}
|
|
|
|
// @codeCoverageIgnoreEnd
|