Code Duplication    Length = 3-3 lines in 2 locations

Script/Command/RedisFlushCommand.php 1 location

@@ 27-29 (lines=3) @@
24
25
        $clients = [];
26
        foreach ($kernel->getContainer()->getServiceIds() as $id) {
27
            if (substr($id, 0, 9) === 'snc_redis' && $kernel->getContainer()->get($id) instanceof Client) {
28
                $clients[] = $id;
29
            }
30
        }
31
32
        foreach ($clients as $snc) {

Script/Controller/ScriptController.php 1 location

@@ 18-20 (lines=3) @@
15
    {
16
        $clients = [];
17
        foreach ($this->container->getServiceIds() as $id) {
18
            if (substr($id, 0, 9) === 'snc_redis' && $this->container->get($id) instanceof Client) {
19
                $clients[] = $id;
20
            }
21
        }
22
23
        foreach ($clients as $snc) {