Code Duplication    Length = 9-9 lines in 2 locations

src/POData/Writers/Atom/AtomODataWriter.php 2 locations

@@ 303-311 (lines=9) @@
300
301
        if ($entry->isMediaLinkEntry) {
302
            $this->xmlWriter->startElement(ODataConstants::ATOM_LINK_ELEMENT_NAME);
303
            if ($entry->mediaLink->eTag != null) {
304
                $this->xmlWriter->startAttributeNs(
305
                    ODataConstants::ODATA_METADATA_NAMESPACE_PREFIX,
306
                    ODataConstants::ATOM_ETAG_ATTRIBUTE_NAME,
307
                    null
308
                );
309
                $this->xmlWriter->text($entry->mediaLink->eTag);
310
                $this->xmlWriter->endAttribute();
311
            }
312
            $this->xmlWriter->startAttribute(
313
                ODataConstants::ATOM_LINK_RELATION_ATTRIBUTE_NAME
314
            );
@@ 334-342 (lines=9) @@
331
332
            foreach ($entry->mediaLinks as $mediaLink) {
333
                $this->xmlWriter->startElement(ODataConstants::ATOM_LINK_ELEMENT_NAME);
334
                if ($mediaLink->eTag != null) {
335
                    $this->xmlWriter->startAttributeNs(
336
                        ODataConstants::ODATA_METADATA_NAMESPACE_PREFIX,
337
                        ODataConstants::ATOM_ETAG_ATTRIBUTE_NAME,
338
                        null
339
                    );
340
                    $this->xmlWriter->text($mediaLink->eTag);
341
                    $this->xmlWriter->endAttribute();
342
                }
343
                $this->xmlWriter->startAttribute(ODataConstants::ATOM_LINK_RELATION_ATTRIBUTE_NAME);
344
                $this->xmlWriter->text(
345
                    'http://schemas.microsoft.com/ado/2007/08/dataservices/mediaresource/'