Code Duplication    Length = 7-9 lines in 2 locations

Parser.php 2 locations

@@ 98-106 (lines=9) @@
95
                continue;
96
            }
97
98
            if (preg_match('/^#EXTINF:(.+),(.*)$/', $line, $matches)) {
99
                $data['playlist'][$mediaSequence]['duration'] = $matches[1];
100
101
                if (isset($matches[2])) {
102
                    $data['playlist'][$mediaSequence]['title'] = $matches[2];
103
                }
104
105
                continue;
106
            }
107
108
            if (preg_match('/^#EXT-X-BYTERANGE:(\d+)(@(\d+))?$/', $line, $matches)) {
109
                $data['playlist'][$mediaSequence]['byteRangeLength'] = (int) $matches[1];
@@ 108-114 (lines=7) @@
105
                continue;
106
            }
107
108
            if (preg_match('/^#EXT-X-BYTERANGE:(\d+)(@(\d+))?$/', $line, $matches)) {
109
                $data['playlist'][$mediaSequence]['byteRangeLength'] = (int) $matches[1];
110
                if (isset($matches[3])) {
111
                    $data['playlist'][$mediaSequence]['byteRangeOffset'] = (int) $matches[3];
112
                }
113
                continue;
114
            }
115
116
            if (preg_match('/^[^#]+/', $line, $matches)) {
117
                $data['playlist'][$mediaSequence]['uri'] = $matches[0];