Various code cleanup.

This commit is contained in:
James Cole
2021-05-24 08:57:02 +02:00
parent d60650cff2
commit ad54163518
21 changed files with 157 additions and 164 deletions

View File

@@ -39,7 +39,7 @@ class AccountList implements BinderInterface
* @param Route $route
*
* @return Collection
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws NotFoundHttpException
*
*/
public static function routeBinder(string $value, Route $route): Collection

View File

@@ -38,7 +38,7 @@ class BudgetList implements BinderInterface
* @param Route $route
*
* @return Collection
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws NotFoundHttpException
*
*/
public static function routeBinder(string $value, Route $route): Collection

View File

@@ -39,7 +39,7 @@ class CLIToken implements BinderInterface
* @param Route $route
*
* @return mixed
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws \FireflyIII\Exceptions\FireflyException
*/
public static function routeBinder(string $value, Route $route)
{
@@ -53,7 +53,7 @@ class CLIToken implements BinderInterface
}
foreach ($users as $user) {
$accessToken = app('preferences')->getForUser($user, 'access_token', null);
$accessToken = app('preferences')->getForUser($user, 'access_token');
if (null !== $accessToken && $accessToken->data === $value) {
Log::info(sprintf('Recognized user #%d (%s) from his acccess token.', $user->id, $user->email));

View File

@@ -37,7 +37,7 @@ class CategoryList implements BinderInterface
* @param Route $route
*
* @return Collection
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws NotFoundHttpException
*
*/
public static function routeBinder(string $value, Route $route): Collection
@@ -54,7 +54,7 @@ class CategoryList implements BinderInterface
throw new NotFoundHttpException;
}
/** @var \Illuminate\Support\Collection $collection */
/** @var Collection $collection */
$collection = auth()->user()->categories()
->whereIn('id', $list)
->get();

View File

@@ -36,7 +36,7 @@ class CurrencyCode implements BinderInterface
* @param Route $route
*
* @return TransactionCurrency
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws NotFoundHttpException
*/
public static function routeBinder(string $value, Route $route): TransactionCurrency
{

View File

@@ -43,7 +43,7 @@ class DynamicConfigKey
* @param Route $route
*
* @return string
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws NotFoundHttpException
*/
public static function routeBinder(string $value, Route $route): string
{

View File

@@ -47,7 +47,7 @@ class EitherConfigKey
* @param Route $route
*
* @return string
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws NotFoundHttpException
*/
public static function routeBinder(string $value, Route $route): string
{

View File

@@ -38,7 +38,7 @@ class JournalList implements BinderInterface
*
* @return array
*
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
* @throws NotFoundHttpException
*/
public static function routeBinder(string $value, Route $route): array
{