Code Duplication    Length = 10-10 lines in 3 locations

src/Discovery/DiscoveryManagerImpl.php 2 locations

@@ 349-358 (lines=10) @@
346
    /**
347
     * {@inheritdoc}
348
     */
349
    public function hasRootTypeDescriptors(Expression $expr = null)
350
    {
351
        $expr2 = Expr::method('getContainingModule', Expr::same($this->rootModule));
352
353
        if ($expr) {
354
            $expr2 = $expr2->andX($expr);
355
        }
356
357
        return $this->hasTypeDescriptors($expr2);
358
    }
359
360
    /**
361
     * {@inheritdoc}
@@ 572-581 (lines=10) @@
569
    /**
570
     * {@inheritdoc}
571
     */
572
    public function hasRootBindingDescriptors(Expression $expr = null)
573
    {
574
        $expr2 = Expr::method('getContainingModule', Expr::same($this->rootModule));
575
576
        if ($expr) {
577
            $expr2 = $expr2->andX($expr);
578
        }
579
580
        return $this->hasBindingDescriptors($expr2);
581
    }
582
583
    /**
584
     * {@inheritdoc}

src/Repository/RepositoryManagerImpl.php 1 location

@@ 330-339 (lines=10) @@
327
    /**
328
     * {@inheritdoc}
329
     */
330
    public function hasRootPathMappings(Expression $expr = null)
331
    {
332
        $expr2 = Expr::method('getContainingModule', Expr::same($this->rootModule));
333
334
        if ($expr) {
335
            $expr2 = $expr2->andX($expr);
336
        }
337
338
        return $this->hasPathMappings($expr2);
339
    }
340
341
    /**
342
     * {@inheritdoc}