Code Duplication    Length = 10-10 lines in 2 locations

src/Bankiru/Api/Rpc/Routing/Loader/YamlLoader.php 2 locations

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