Code Duplication    Length = 5-6 lines in 2 locations

src/PhpSpreadsheet/Reader/Xls.php 2 locations

@@ 2099-2103 (lines=5) @@
2096
            // offset: 12; size: 1; character set
2097
            // offset: 13; size: 1; not used
2098
            // offset: 14; size: var; font name
2099
            if ($this->version == self::XLS_BIFF8) {
2100
                $string = self::readUnicodeStringShort(substr($recordData, 14));
2101
            } else {
2102
                $string = $this->readByteStringShort(substr($recordData, 14));
2103
            }
2104
            $objFont->setName($string['value']);
2105
2106
            $this->objFonts[] = $objFont;
@@ 2135-2140 (lines=6) @@
2132
        if (!$this->readDataOnly) {
2133
            $indexCode = self::getUInt2d($recordData, 0);
2134
2135
            if ($this->version == self::XLS_BIFF8) {
2136
                $string = self::readUnicodeStringLong(substr($recordData, 2));
2137
            } else {
2138
                // BIFF7
2139
                $string = $this->readByteStringShort(substr($recordData, 2));
2140
            }
2141
2142
            $formatString = $string['value'];
2143
            $this->formats[$indexCode] = $formatString;