Code Duplication    Length = 10-10 lines in 2 locations

Routing/Loader/YamlLoader.php 2 locations

@@ 128-137 (lines=10) @@
125
                )
126
            );
127
        }
128
        if (isset($config['resource']) && isset($config['method'])) {
129
            throw new \InvalidArgumentException(
130
                sprintf(
131
                    'The routing file "%s" must not specify both the "resource" key and the "path" key for "%s". ' .
132
                    'Choose between an import and a route definition.',
133
                    $path,
134
                    $name
135
                )
136
            );
137
        }
138
        if (!isset($config['resource']) && isset($config['type'])) {
139
            throw new \InvalidArgumentException(
140
                sprintf(
@@ 138-147 (lines=10) @@
135
                )
136
            );
137
        }
138
        if (!isset($config['resource']) && isset($config['type'])) {
139
            throw new \InvalidArgumentException(
140
                sprintf(
141
                    'The "type" key for the route definition "%s" in "%s" is unsupported. ' .
142
                    'It is only available for imports in combination with the "resource" key.',
143
                    $name,
144
                    $path
145
                )
146
            );
147
        }
148
    }
149
150
    /**