Skip to content
This repository was archived by the owner on Feb 7, 2024. It is now read-only.

Commit 14a7944

Browse files
committed
Added $processCollection to the getForGraph method
1 parent 9a6e8e3 commit 14a7944

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

src/Contracts/StatisticsStore.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ public function getRecords(callable $processQuery = null, callable $processColle
4848
* format that is easily to read for graphs.
4949
*
5050
* @param callable $processQuery
51+
* @param callable $processCollection
5152
* @return array
5253
*/
53-
public function getForGraph(callable $processQuery = null): array;
54+
public function getForGraph(callable $processQuery = null, callable $processCollection = null): array;
5455
}

src/Statistics/Stores/DatabaseStore.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,12 +86,13 @@ public function getRecords(callable $processQuery = null, callable $processColle
8686
* format that is easily to read for graphs.
8787
*
8888
* @param callable $processQuery
89+
* @param callable $processCollection
8990
* @return array
9091
*/
91-
public function getForGraph(callable $processQuery = null): array
92+
public function getForGraph(callable $processQuery = null, callable $processCollection = null): array
9293
{
9394
$statistics = collect(
94-
$this->getRecords($processQuery)
95+
$this->getRecords($processQuery, $processCollection)
9596
);
9697

9798
return $this->statisticsToGraph($statistics);

0 commit comments

Comments
 (0)