Code Duplication    Length = 8-8 lines in 2 locations

src/Resource/GenericResource.php 1 location

@@ 74-81 (lines=8) @@
71
    /**
72
     * {@inheritdoc}
73
     */
74
    public function getChild($relPath)
75
    {
76
        if (!$this->getRepository()) {
77
            throw ResourceNotFoundException::forPath($this->getRepositoryPath().'/'.$relPath);
78
        }
79
80
        return $this->getRepository()->get($this->getRepositoryPath().'/'.$relPath);
81
    }
82
83
    /**
84
     * {@inheritdoc}

src/Resource/LinkResource.php 1 location

@@ 67-74 (lines=8) @@
64
    /**
65
     * {@inheritdoc}
66
     */
67
    public function getChild($relPath)
68
    {
69
        if (!$this->getRepository()) {
70
            throw ResourceNotFoundException::forPath($this->getTargetPath().'/'.$relPath);
71
        }
72
73
        return $this->getRepository()->get($this->getTargetPath().'/'.$relPath);
74
    }
75
76
    /**
77
     * {@inheritdoc}