Fix some errors found in debug logs.

This commit is contained in:
James Cole
2018-07-27 03:09:35 +02:00
parent d6298d9f05
commit 2ad8e7f343
5 changed files with 10 additions and 10 deletions

View File

@@ -176,7 +176,7 @@ class CategoryController extends Controller
$cache->addProperty($accounts->pluck('id')->toArray());
$cache->addProperty($category);
if ($cache->has()) {
return $cache->get(); // @codeCoverageIgnore
return response()->json($cache->get());// @codeCoverageIgnore
}
$repository = app(CategoryRepositoryInterface::class);
$expenses = $repository->periodExpenses(new Collection([$category]), $accounts, $start, $end);
@@ -237,7 +237,7 @@ class CategoryController extends Controller
$cache->addProperty('chart.category.period.no-cat');
$cache->addProperty($accounts->pluck('id')->toArray());
if ($cache->has()) {
return $cache->get(); // @codeCoverageIgnore
return response()->json($cache->get()); // @codeCoverageIgnore
}
$repository = app(CategoryRepositoryInterface::class);
$expenses = $repository->periodExpensesNoCategory($accounts, $start, $end);