Code Duplication    Length = 5-5 lines in 2 locations

Services/PaywallService.php 2 locations

@@ 551-555 (lines=5) @@
548
        $attribute = $duration['attribute'];
549
        $timeSpan = null;
550
        switch ($attribute) {
551
            case Duration::MONTHS:
552
                $diffrence = (int) $now->diff($createdAt)->format('%m');
553
                $months = $value + $diffrence;
554
                $timeSpan = new \DateInterval('P'.$months.'M');
555
                break;
556
            case Duration::DAYS:
557
                $daysDiffrence = (int) $now->diff($createdAt)->format('%a');
558
                $days = $value + $daysDiffrence;
@@ 556-560 (lines=5) @@
553
                $months = $value + $diffrence;
554
                $timeSpan = new \DateInterval('P'.$months.'M');
555
                break;
556
            case Duration::DAYS:
557
                $daysDiffrence = (int) $now->diff($createdAt)->format('%a');
558
                $days = $value + $daysDiffrence;
559
                $timeSpan = new \DateInterval('P'.$days.'D');
560
                break;
561
        }
562
563
        return $startDate->add($timeSpan);