Code Duplication    Length = 7-7 lines in 2 locations

src/Services/AnalyticsService.php 2 locations

@@ 46-52 (lines=7) @@
43
        }
44
    }
45
46
    public function topReferers($count)
47
    {
48
        $analytics = $this->model->where('created_at', '>', Carbon::now()->subDays($count))->get();
49
        $data = $analytics->pluck('data')->all();
50
51
        return $this->convertDataToItems($data, 'referer', ['unknown' => 0]);
52
    }
53
54
    public function topPages($count)
55
    {
@@ 54-60 (lines=7) @@
51
        return $this->convertDataToItems($data, 'referer', ['unknown' => 0]);
52
    }
53
54
    public function topPages($count)
55
    {
56
        $analytics = $this->model->where('created_at', '>', Carbon::now()->subDays($count))->get();
57
        $data = $analytics->pluck('data')->all();
58
59
        return $this->convertDataToItems($data, 'uri');
60
    }
61
62
    public function topBrowsers($count)
63
    {