Code Duplication    Length = 7-7 lines in 2 locations

src/Xtools/ArticleInfo.php 2 locations

@@ 264-270 (lines=7) @@
261
     * Get the average number of edits per month to the page.
262
     * @return double
263
     */
264
    public function editsPerMonth()
265
    {
266
        $editsPerMonth = $this->getTotalDays()
267
            ? $this->getNumRevisionsProcessed() / ($this->getTotalDays() / (365 / 12))
268
            : 0;
269
        return min($this->getNumRevisionsProcessed(), round($editsPerMonth, 1));
270
    }
271
272
    /**
273
     * Get the average number of edits per year to the page.
@@ 276-282 (lines=7) @@
273
     * Get the average number of edits per year to the page.
274
     * @return double
275
     */
276
    public function editsPerYear()
277
    {
278
        $editsPerYear = $this->getTotalDays()
279
            ? $this->getNumRevisionsProcessed() / ($this->getTotalDays() / 365)
280
            : 0;
281
        return min($this->getNumRevisionsProcessed(), round($editsPerYear, 1));
282
    }
283
284
    /**
285
     * Get the average number of edits per editor.