@@ -37,31 +37,31 @@ public function __construct(
3737 /** @var iterable<BounceProtocolProcessor> */
3838 private readonly iterable $ protocolProcessors ,
3939 private readonly AdvancedBounceRulesProcessor $ advancedRulesProcessor ,
40- private readonly UnidentifiedBounceReprocessor $ unidentifiedBounceReprocessor ,
40+ private readonly UnidentifiedBounceReprocessor $ unidentifiedReprocessor ,
4141 private readonly ConsecutiveBounceHandler $ consecutiveBounceHandler ,
4242 ) {
4343 parent ::__construct ();
4444 }
4545
4646 protected function execute (InputInterface $ input , OutputInterface $ output ): int
4747 {
48- $ io = new SymfonyStyle ($ input , $ output );
48+ $ inputOutput = new SymfonyStyle ($ input , $ output );
4949
5050 if (!function_exists ('imap_open ' )) {
51- $ io ->note ('PHP IMAP extension not available. Falling back to Webklex IMAP where applicable. ' );
51+ $ inputOutput ->note ('PHP IMAP extension not available. Falling back to Webklex IMAP where applicable. ' );
5252 }
5353
5454 $ force = (bool )$ input ->getOption ('force ' );
5555 $ lock = $ this ->lockService ->acquirePageLock ('bounce_processor ' , $ force );
5656
5757 if (!$ lock ) {
58- $ io ->warning ('Another bounce processing is already running. Aborting. ' );
58+ $ inputOutput ->warning ('Another bounce processing is already running. Aborting. ' );
5959
6060 return Command::SUCCESS ;
6161 }
6262
6363 try {
64- $ io ->title ('Processing bounces ' );
64+ $ inputOutput ->title ('Processing bounces ' );
6565 $ protocol = (string )$ input ->getOption ('protocol ' );
6666
6767 $ downloadReport = '' ;
@@ -75,23 +75,23 @@ protected function execute(InputInterface $input, OutputInterface $output): int
7575 }
7676
7777 if ($ processor === null ) {
78- $ io ->error ('Unsupported protocol: ' .$ protocol );
78+ $ inputOutput ->error ('Unsupported protocol: ' .$ protocol );
7979
8080 return Command::FAILURE ;
8181 }
8282
83- $ downloadReport .= $ processor ->process ($ input , $ io );
84- $ this ->unidentifiedBounceReprocessor ->process ($ io );
85- $ this ->advancedRulesProcessor ->process ($ io , (int )$ input ->getOption ('rules-batch-size ' ));
86- $ this ->consecutiveBounceHandler ->handle ($ io );
83+ $ downloadReport .= $ processor ->process ($ input , $ inputOutput );
84+ $ this ->unidentifiedReprocessor ->process ($ inputOutput );
85+ $ this ->advancedRulesProcessor ->process ($ inputOutput , (int )$ input ->getOption ('rules-batch-size ' ));
86+ $ this ->consecutiveBounceHandler ->handle ($ inputOutput );
8787
8888 $ this ->logger ->info ('Bounce processing completed ' , ['downloadReport ' => $ downloadReport ]);
89- $ io ->success ('Bounce processing completed. ' );
89+ $ inputOutput ->success ('Bounce processing completed. ' );
9090
9191 return Command::SUCCESS ;
9292 } catch (Exception $ e ) {
9393 $ this ->logger ->error ('Bounce processing failed ' , ['exception ' => $ e ]);
94- $ io ->error ('Error: ' .$ e ->getMessage ());
94+ $ inputOutput ->error ('Error: ' .$ e ->getMessage ());
9595
9696 return Command::FAILURE ;
9797 } finally {
0 commit comments