Code Duplication    Length = 9-9 lines in 2 locations

Protocol/Parser/AtomParser.php 1 location

@@ 167-175 (lines=9) @@
164
     * @param SimpleXMLElement $element
165
     * @param ItemInInterface $item
166
     */
167
    protected function parseCategories(SimpleXMLElement $element, ItemInInterface $item)
168
    {
169
        foreach ($element->category as $xmlCategory) {
170
            $category = new Category();
171
            $category->setName($this->getAttributeValue($xmlCategory, 'term'));
172
173
            $item->addCategory($category);
174
        }
175
    }
176
}
177

Protocol/Parser/RssParser.php 1 location

@@ 193-201 (lines=9) @@
190
     * @param SimpleXMLElement $element
191
     * @param ItemInInterface $item
192
     */
193
    protected function parseCategories(SimpleXMLElement $element, ItemInInterface $item)
194
    {
195
        foreach ($element->category as $xmlCategory) {
196
            $category = new Category();
197
            $category->setName((string) $xmlCategory);
198
199
            $item->addCategory($category);
200
        }
201
    }
202
203
    /**
204
     * Parse author: