Code Duplication    Length = 11-11 lines in 2 locations

src/voku/helper/SimpleHtmlDom.php 1 location

@@ 465-475 (lines=11) @@
462
     *
463
     * @return SimpleHtmlDomInterface|null
464
     */
465
    public function firstChild()
466
    {
467
        /** @var \DOMNode|null $node */
468
        $node = $this->node->firstChild;
469
470
        if ($node === null) {
471
            return null;
472
        }
473
474
        return new static($node);
475
    }
476
477
    /**
478
     * Return elements by ".class".

src/voku/helper/SimpleXmlDom.php 1 location

@@ 434-444 (lines=11) @@
431
     *
432
     * @return SimpleXmlDomInterface|null
433
     */
434
    public function firstChild()
435
    {
436
        /** @var \DOMNode|null $node */
437
        $node = $this->node->firstChild;
438
439
        if ($node === null) {
440
            return null;
441
        }
442
443
        return new static($node);
444
    }
445
446
    /**
447
     * Return elements by ".class".