| 16766 | 
           efrain | 
           1 | 
           <?php
  | 
        
        
            | 
            | 
           2 | 
           declare(strict_types=1);
  | 
        
        
            | 
            | 
           3 | 
           namespace LeadersLinked\Factory\Command;
  | 
        
        
            | 
            | 
           4 | 
              | 
        
        
            | 
            | 
           5 | 
           use Laminas\ServiceManager\Factory\FactoryInterface;
  | 
        
        
            | 
            | 
           6 | 
           use LeadersLinked\Command\DuplicateDiscoveryContactCommand;
  | 
        
        
            | 
            | 
           7 | 
           use Psr\Container\ContainerInterface;
  | 
        
        
            | 
            | 
           8 | 
              | 
        
        
            | 
            | 
           9 | 
              | 
        
        
            | 
            | 
           10 | 
           class DuplicateDiscoveryContactCommandFactory implements FactoryInterface
  | 
        
        
            | 
            | 
           11 | 
           {
  | 
        
        
            | 
            | 
           12 | 
               public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
  | 
        
        
            | 
            | 
           13 | 
               {
  | 
        
        
            | 
            | 
           14 | 
              | 
        
        
            | 
            | 
           15 | 
                   $db         = $container->get('leaders-linked-db');
  | 
        
        
            | 
            | 
           16 | 
                   $log        = $container->get('leaders-linked-log');
  | 
        
        
            | 
            | 
           17 | 
                   $config     = $container->get('ServiceManager')->get('config');
  | 
        
        
            | 
            | 
           18 | 
              | 
        
        
            | 
            | 
           19 | 
              | 
        
        
            | 
            | 
           20 | 
                   $config = array_filter($config, function($k) {
  | 
        
        
            | 
            | 
           21 | 
                       return strpos($k, 'leaderslinked.') !== false;
  | 
        
        
            | 
            | 
           22 | 
                   }, ARRAY_FILTER_USE_KEY);
  | 
        
        
            | 
            | 
           23 | 
              | 
        
        
           | 16768 | 
           efrain | 
           24 | 
                   return new DuplicateDiscoveryContactCommand($db, $log,  $config);
  | 
        
        
           | 16766 | 
           efrain | 
           25 | 
               }
  | 
        
        
            | 
            | 
           26 | 
              | 
        
        
            | 
            | 
           27 | 
           }
  |