extracted interfaces for services, to aid in creating tests

This commit is contained in:
2026-06-05 15:15:21 -04:00
parent 0813323ac2
commit 7cf7e04d17
10 changed files with 81 additions and 20 deletions
+3 -3
View File
@@ -4,7 +4,7 @@ declare(strict_types=1);
namespace App\Command;
use App\PersistCache;
use App\Service\BackupCodeManager;
use App\Service\BackupCodeInterface;
use Psr\Cache\InvalidArgumentException;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputArgument;
@@ -15,8 +15,8 @@ use Symfony\Component\Console\Output\OutputInterface;
* usage: php bin/console app:generate-backup-codes [count] */
final class GenerateBackupCodesCommand extends Command {
public function __construct(
private readonly BackupCodeManager $manager,
private readonly PersistCache $persistCache,
private readonly BackupCodeInterface $manager,
private readonly PersistCache $persistCache,
) {
parent::__construct();
}