mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Various code cleanup.
This commit is contained in:
@@ -54,12 +54,12 @@ class BudgetList implements BinderInterface
|
||||
|
||||
$list = array_unique(array_map('\intval', explode(',', $value)));
|
||||
|
||||
// @codeCoverageIgnoreStart
|
||||
|
||||
if (0 === count($list)) {
|
||||
Log::warning('Budget list count is zero, return 404.');
|
||||
throw new NotFoundHttpException;
|
||||
}
|
||||
// @codeCoverageIgnoreEnd
|
||||
|
||||
|
||||
/** @var Collection $collection */
|
||||
$collection = auth()->user()->budgets()
|
||||
|
||||
@@ -51,7 +51,7 @@ class CategoryList implements BinderInterface
|
||||
|
||||
$list = array_unique(array_map('\intval', explode(',', $value)));
|
||||
if (0 === count($list)) {
|
||||
throw new NotFoundHttpException; // @codeCoverageIgnore
|
||||
throw new NotFoundHttpException;
|
||||
}
|
||||
|
||||
/** @var \Illuminate\Support\Collection $collection */
|
||||
|
||||
@@ -69,7 +69,7 @@ class JournalList implements BinderInterface
|
||||
{
|
||||
$list = array_unique(array_map('\intval', explode(',', $value)));
|
||||
if (0 === count($list)) {
|
||||
throw new NotFoundHttpException; // @codeCoverageIgnore
|
||||
throw new NotFoundHttpException;
|
||||
}
|
||||
|
||||
return $list;
|
||||
|
||||
@@ -52,12 +52,12 @@ class TagList implements BinderInterface
|
||||
}
|
||||
$list = array_unique(array_map('\strtolower', explode(',', $value)));
|
||||
Log::debug('List of tags is', $list);
|
||||
// @codeCoverageIgnoreStart
|
||||
|
||||
if (0 === count($list)) {
|
||||
Log::error('Tag list is empty.');
|
||||
throw new NotFoundHttpException;
|
||||
}
|
||||
// @codeCoverageIgnoreEnd
|
||||
|
||||
|
||||
/** @var TagRepositoryInterface $repository */
|
||||
$repository = app(TagRepositoryInterface::class);
|
||||
|
||||
Reference in New Issue
Block a user