Code Duplication    Length = 8-8 lines in 2 locations

src/Resource/FieldMap.php 1 location

@@ 35-42 (lines=8) @@
32
     *
33
     * @throws FieldNotFoundException
34
     */
35
    public function getField($name)
36
    {
37
        if (!array_key_exists($name, $this->fields)) {
38
            throw new FieldNotFoundException($name);
39
        }
40
41
        return $this->fields[$name];
42
    }
43
44
    public function matches($criteria)
45
    {

src/Resource/Resource.php 1 location

@@ 54-61 (lines=8) @@
51
     *
52
     * @throws FieldNotFoundException
53
     */
54
    public function getField($name)
55
    {
56
        if (!array_key_exists($name, $this->fields)) {
57
            throw new FieldNotFoundException($name);
58
        }
59
60
        return $this->fields[$name];
61
    }
62
63
    /** @return string[] */
64
    public function getLinks()