Code Duplication    Length = 3-3 lines in 3 locations

src/Recurrence/RruleTransformer/DtStartTransformer.php 3 locations

@@ 27-29 (lines=3) @@
24
            }
25
        }
26
27
        if (preg_match('/'.$this::RRULE_PARAMETER.'=([0-9]{8}T[0-9]{6}Z)/', $rRule, $matches)) {
28
            return \DateTime::createFromFormat('Ymd\THisZ', $matches[1], new \DateTimeZone('UTC'));
29
        }
30
31
        if (preg_match('/'.$this::RRULE_PARAMETER.'=([0-9]{8}T[0-9]{6})/', $rRule, $matches)) {
32
            return \DateTime::createFromFormat('Ymd\THis', $matches[1]);
@@ 31-33 (lines=3) @@
28
            return \DateTime::createFromFormat('Ymd\THisZ', $matches[1], new \DateTimeZone('UTC'));
29
        }
30
31
        if (preg_match('/'.$this::RRULE_PARAMETER.'=([0-9]{8}T[0-9]{6})/', $rRule, $matches)) {
32
            return \DateTime::createFromFormat('Ymd\THis', $matches[1]);
33
        }
34
35
        if (preg_match('/'.$this::RRULE_PARAMETER.'=([0-9]{8})/', $rRule, $matches)) {
36
            return \DateTime::createFromFormat('Ymd', $matches[1]);
@@ 35-37 (lines=3) @@
32
            return \DateTime::createFromFormat('Ymd\THis', $matches[1]);
33
        }
34
35
        if (preg_match('/'.$this::RRULE_PARAMETER.'=([0-9]{8})/', $rRule, $matches)) {
36
            return \DateTime::createFromFormat('Ymd', $matches[1]);
37
        }
38
39
        $this->throwExceptionOnInvalidParameter($rRule, $this::RRULE_PARAMETER);
40