🤖 Auto commit for release 'develop' on 2025-10-05

This commit is contained in:
JC5
2025-10-05 13:03:51 +02:00
parent 50279d623c
commit b0033cf9ed
180 changed files with 285 additions and 455 deletions

View File

@@ -259,7 +259,6 @@ class BudgetController extends Controller
return $return;
}
private function filterLimit(int $currencyId, Collection $limits): ?BudgetLimit
{
$amount = '0';

View File

@@ -31,6 +31,7 @@ use FireflyIII\Exceptions\FireflyException;
use FireflyIII\Support\Export\ExportDataGenerator;
use Illuminate\Http\Response as LaravelResponse;
use Safe\Exceptions\DatetimeException;
use function Safe\date;
/**
@@ -60,11 +61,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function accounts(ExportRequest $request): LaravelResponse
@@ -102,11 +101,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function bills(ExportRequest $request): LaravelResponse
@@ -117,11 +114,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function budgets(ExportRequest $request): LaravelResponse
@@ -132,11 +127,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function categories(ExportRequest $request): LaravelResponse
@@ -147,11 +140,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function piggyBanks(ExportRequest $request): LaravelResponse
@@ -162,11 +153,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function recurring(ExportRequest $request): LaravelResponse
@@ -177,11 +166,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function rules(ExportRequest $request): LaravelResponse
@@ -192,11 +179,9 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*
* @SuppressWarnings("PHPMD.UnusedFormalParameter")
*/
public function tags(ExportRequest $request): LaravelResponse
@@ -207,9 +192,6 @@ class ExportController extends Controller
}
/**
* @param ExportRequest $request
*
* @return LaravelResponse
* @throws DatetimeException
* @throws FireflyException
*/

View File

@@ -69,8 +69,6 @@ class ListController extends Controller
);
}
/**
*/
public function attachments(Account $account): JsonResponse
{
$manager = $this->getManager();
@@ -94,8 +92,6 @@ class ListController extends Controller
return response()->json($manager->createData($resource)->toArray())->header('Content-Type', self::CONTENT_TYPE);
}
/**
*/
public function piggyBanks(Account $account): JsonResponse
{
// create some objects:
@@ -132,7 +128,6 @@ class ListController extends Controller
/**
* Show all transaction groups related to the account.
*
*/
public function transactions(Request $request, Account $account): JsonResponse
{

View File

@@ -67,7 +67,6 @@ class ShowController extends Controller
/**
* Display a listing of the resource.
*
*/
public function index(ShowRequest $request): JsonResponse
{

View File

@@ -119,7 +119,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/attachments/listAttachment
*
* Display a listing of the resource.
*
*/
public function index(): JsonResponse
{

View File

@@ -66,7 +66,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/available_budgets/getAvailableBudget
*
* Display a listing of the resource.
*
*/
public function index(): JsonResponse
{

View File

@@ -70,7 +70,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/bills/listAttachmentByBill
*
* Display a listing of the resource.
*
*/
public function attachments(Bill $bill): JsonResponse
{
@@ -100,7 +99,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/bills/listRuleByBill
*
* List all of them.
*
*/
public function rules(Bill $bill): JsonResponse
{
@@ -132,7 +130,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/bills/listTransactionByBill
*
* Show all transactions.
*
*/
public function transactions(Request $request, Bill $bill): JsonResponse
{

View File

@@ -64,7 +64,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/bills/listBill
*
* Display a listing of the resource.
*
*/
public function index(): JsonResponse
{

View File

@@ -72,7 +72,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/budgets/listAttachmentByBudget
*
*/
public function attachments(Budget $budget): JsonResponse
{
@@ -102,7 +101,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/budgets/listBudgetLimitByBudget
*
* Display a listing of the resource.
*
*/
public function budgetLimits(Budget $budget): JsonResponse
{
@@ -137,7 +135,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/budgets/listTransactionByBudget
*
* Show all transactions.
*
*/
public function transactions(Request $request, Budget $budget): JsonResponse
{
@@ -198,7 +195,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/budgets/listTransactionWithoutBudget
*
* Show all transactions.
*
*/
public function withoutBudget(Request $request): JsonResponse
{

View File

@@ -68,7 +68,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/budgets/listBudget
*
* Display a listing of the resource.
*
*/
public function index(): JsonResponse
{

View File

@@ -48,7 +48,6 @@ class ListController extends Controller
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/budgets/listTransactionByBudgetLimit
* Show all transactions.
*
*/
public function transactions(Request $request, Budget $budget, BudgetLimit $budgetLimit): JsonResponse
{

View File

@@ -67,7 +67,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/categories/listAttachmentByCategory
*
*/
public function attachments(Category $category): JsonResponse
{
@@ -97,7 +96,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/categories/listTransactionByCategory
*
* Show all transactions.
*
*/
public function transactions(Request $request, Category $category): JsonResponse
{

View File

@@ -64,7 +64,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/categories/listCategory
*
* Display a listing of the resource.
*
*/
public function index(): JsonResponse
{

View File

@@ -67,7 +67,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/object_groups/listBillByObjectGroup
*
* List all bills in this object group
*
*/
public function bills(ObjectGroup $objectGroup): JsonResponse
{
@@ -107,7 +106,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/object_groups/listPiggyBankByObjectGroup
*
* List all piggies under the object group.
*
*/
public function piggyBanks(ObjectGroup $objectGroup): JsonResponse
{

View File

@@ -66,7 +66,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/piggy_banks/listAccountByPiggyBank
*
* List single resource.
*
*/
public function accounts(PiggyBank $piggyBank): JsonResponse
{
@@ -103,7 +102,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/piggy_banks/listAttachmentByPiggyBank
*
*/
public function attachments(PiggyBank $piggyBank): JsonResponse
{
@@ -133,7 +131,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/piggy_banks/listEventByPiggyBank
*
* List single resource.
*
*/
public function piggyBankEvents(PiggyBank $piggyBank): JsonResponse
{

View File

@@ -64,7 +64,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/piggy_banks/listPiggyBank
*
* List all of them.
*
*/
public function index(): JsonResponse
{

View File

@@ -67,7 +67,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/recurrences/listTransactionByRecurrence
*
* Show transactions for this recurrence.
*
*/
public function transactions(Request $request, Recurrence $recurrence): JsonResponse
{

View File

@@ -64,7 +64,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/recurrences/listRecurrence
*
* List all of them.
*
*/
public function index(): JsonResponse
{

View File

@@ -66,7 +66,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/rules/listRule
*
* List all of them.
*
*/
public function index(): JsonResponse
{

View File

@@ -63,7 +63,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/rule_groups/listRuleByGroup
*
*/
public function rules(RuleGroup $group): JsonResponse
{

View File

@@ -65,7 +65,6 @@ class ShowController extends Controller
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/rule_groups/listRuleGroup
* List all of them.
*
*/
public function index(): JsonResponse
{

View File

@@ -70,7 +70,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/tags/listAttachmentByTag
*
*/
public function attachments(Tag $tag): JsonResponse
{
@@ -100,7 +99,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/tags/listTransactionByTag
*
* Show all transactions.
*
*/
public function transactions(Request $request, Tag $tag): JsonResponse
{

View File

@@ -66,7 +66,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/tags/listTag
*
* List all of them.
*
*/
public function index(): JsonResponse
{

View File

@@ -68,7 +68,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/transactions/listAttachmentByTransaction
*
*/
public function attachments(TransactionGroup $transactionGroup): JsonResponse
{
@@ -99,7 +98,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/transactions/listEventByTransaction
*
*/
public function piggyBankEvents(TransactionGroup $transactionGroup): JsonResponse
{
@@ -141,7 +139,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/transactions/listLinksByJournal
*
*/
public function transactionLinks(TransactionJournal $transactionJournal): JsonResponse
{

View File

@@ -51,7 +51,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/transactions/listTransaction
*
* Show all transactions.
*
*/
public function index(Request $request): JsonResponse
{

View File

@@ -70,7 +70,6 @@ class ListController extends Controller
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listAccountByCurrency
* Display a list of accounts.
*
*/
public function accounts(Request $request, TransactionCurrency $currency): JsonResponse
{
@@ -127,7 +126,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listAvailableBudgetByCurrency
*
* Display a listing of the resource.
*
*/
public function availableBudgets(TransactionCurrency $currency): JsonResponse
{
@@ -161,7 +159,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listBillByCurrency
*
* List all bills
*
*/
public function bills(TransactionCurrency $currency): JsonResponse
{
@@ -207,7 +204,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listBudgetLimitByCurrency
*
* List all budget limits
*
*/
public function budgetLimits(TransactionCurrency $currency): JsonResponse
{
@@ -244,7 +240,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listRecurrenceByCurrency
*
* List all recurring transactions.
*
*/
public function recurrences(TransactionCurrency $currency): JsonResponse
{
@@ -296,7 +291,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listRuleByCurrency
*
* List all of them.
*
*/
public function rules(TransactionCurrency $currency): JsonResponse
{
@@ -340,7 +334,6 @@ class ListController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listTransactionByCurrency
*
* Show all transactions.
*
*/
public function transactions(Request $request, TransactionCurrency $currency): JsonResponse
{

View File

@@ -68,7 +68,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/listCurrency
*
* Display a listing of the resource.
*
*/
public function index(): JsonResponse
{
@@ -97,7 +96,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/getCurrency
*
* Show a currency.
*
*/
public function show(TransactionCurrency $currency): JsonResponse
{
@@ -120,7 +118,6 @@ class ShowController extends Controller
/**
* Show a currency.
*
*/
public function showPrimary(): JsonResponse
{

View File

@@ -65,7 +65,6 @@ class StoreController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/storeCurrency
*
* Store new currency.
*
*/
public function store(StoreRequest $request): JsonResponse
{

View File

@@ -98,8 +98,6 @@ class UpdateController extends Controller
return response()->json($manager->createData($resource)->toArray())->header('Content-Type', self::CONTENT_TYPE);
}
/**
*/
public function makePrimary(TransactionCurrency $currency): JsonResponse
{
/** @var User $user */
@@ -126,7 +124,6 @@ class UpdateController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/currencies/enableCurrency
*
* Enable a currency.
*
*/
public function enable(TransactionCurrency $currency): JsonResponse
{

View File

@@ -68,7 +68,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/links/listTransactionLink
*
* List all transaction links there are.
*
*/
public function index(Request $request): JsonResponse
{

View File

@@ -67,7 +67,6 @@ class ListController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/links/listTransactionByLinkType
*
*/
public function transactions(Request $request, LinkType $linkType): JsonResponse
{

View File

@@ -66,7 +66,6 @@ class ShowController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/links/listLinkType
*
*/
public function index(): JsonResponse
{

View File

@@ -41,7 +41,6 @@ class TransactionController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/search/searchTransactions
*
*/
public function search(Request $request, SearchInterface $searcher): JsonResponse
{

View File

@@ -90,7 +90,6 @@ class UserController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/users/listUser
*
* Display a listing of the resource.
*
*/
public function index(): JsonResponse
{

View File

@@ -49,7 +49,6 @@ class PreferencesController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/preferences/listPreference
*
* List all of them.
*
*/
public function index(): JsonResponse
{

View File

@@ -62,7 +62,6 @@ class MessageController extends Controller
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/webhooks/getWebhookMessages
*
*/
public function index(Webhook $webhook): JsonResponse
{

View File

@@ -69,7 +69,6 @@ class ShowController extends Controller
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/webhooks/listWebhook
*
* Display a listing of the webhooks of the user.
*
*/
public function index(): JsonResponse
{

View File

@@ -33,6 +33,7 @@ use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
use JsonException;
use function Safe\json_decode;
/**

View File

@@ -40,6 +40,7 @@ use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Log;
use InvalidArgumentException;
use Safe\Exceptions\FilesystemException;
use function Safe\file_put_contents;
class ExportsData extends Command
@@ -275,9 +276,6 @@ class ExportsData extends Command
}
/**
* @param array $options
* @param array $data
*
* @throws FireflyException
* @throws FilesystemException
*/

View File

@@ -42,6 +42,7 @@ use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Log;
use function Safe\json_encode;
use function Safe\mb_regex_encoding;

View File

@@ -28,6 +28,7 @@ namespace FireflyIII\Console\Commands\System;
use FireflyIII\Console\Commands\ShowsFriendlyMessages;
use Illuminate\Console\Command;
use Symfony\Component\Console\Command\Command as CommandAlias;
use function Safe\file_put_contents;
use function Safe\json_encode;

View File

@@ -34,6 +34,7 @@ use Illuminate\Support\Facades\Storage;
use Safe\Exceptions\FileinfoException;
use Safe\Exceptions\FilesystemException;
use Safe\Exceptions\StringsException;
use function Safe\file_put_contents;
use function Safe\md5_file;
use function Safe\mime_content_type;

View File

@@ -31,6 +31,7 @@ use Illuminate\Support\Facades\Log;
use Illuminate\Support\Facades\Storage;
use League\Flysystem\FilesystemException;
use Safe\Exceptions\JsonException;
use function Safe\json_decode;
class VerifySecurityAlerts extends Command
@@ -44,7 +45,6 @@ class VerifySecurityAlerts extends Command
/**
* Execute the console command.
*
* @return int
* @throws FilesystemException
* @throws JsonException
*/

View File

@@ -52,7 +52,6 @@ class AddsTransactionIdentifiers extends Command
*
* When either of these are the same amount, FF3 can't keep them apart: +3/-3, +3/-3, +3/-3. This happens more
* often than you would think. So each set gets a number (1,2,3) to keep them apart.
*
*/
public function handle(): int
{
@@ -99,6 +98,7 @@ class AddsTransactionIdentifiers extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -34,6 +34,7 @@ use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Log;
use JsonException;
use stdClass;
use function Safe\json_decode;
class RemovesDatabaseDecryption extends Command
@@ -98,6 +99,7 @@ class RemovesDatabaseDecryption extends Command
} catch (FireflyException $e) {
Log::error($e->getMessage());
}
return (bool)$configVar?->data;
}

View File

@@ -98,8 +98,6 @@ class UpgradesAccountCurrencies extends Command
}
}
/**
*/
private function updateCurrenciesForUser(User $user): void
{
$this->accountRepos->setUser($user);

View File

@@ -83,6 +83,7 @@ class UpgradesAccountMetaData extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -93,6 +93,7 @@ class UpgradesAttachments extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -99,13 +99,13 @@ class UpgradesBillsToRules extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}
/**
* Migrate bills to new rule structure for a specific user.
*
*/
private function migrateUser(User $user): void
{

View File

@@ -85,6 +85,7 @@ class UpgradesBudgetLimits extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -66,6 +66,7 @@ class UpgradesCurrencyPreferences extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -29,6 +29,7 @@ use FireflyIII\Support\Facades\FireflyConfig;
use Illuminate\Console\Command;
use Illuminate\Support\Facades\Log;
use Safe\Exceptions\InfoException;
use function Safe\set_time_limit;
try {

View File

@@ -87,6 +87,7 @@ class UpgradesJournalNotes extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -62,6 +62,7 @@ class UpgradesLiabilities extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -64,6 +64,7 @@ class UpgradesLiabilitiesEight extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -65,6 +65,7 @@ class UpgradesMultiPiggyBanks extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -61,6 +61,7 @@ class UpgradesPrimaryCurrencyAmounts extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -29,6 +29,7 @@ use FireflyIII\Models\Recurrence;
use FireflyIII\Models\RecurrenceMeta;
use FireflyIII\Models\RecurrenceTransactionMeta;
use Illuminate\Console\Command;
use function Safe\json_encode;
class UpgradesRecurrenceMetaData extends Command
@@ -65,6 +66,7 @@ class UpgradesRecurrenceMetaData extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -64,6 +64,7 @@ class UpgradesRuleActions extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -58,6 +58,7 @@ class UpgradesTagLocations extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -98,6 +98,7 @@ class UpgradesToGroups extends Command
private function isMigrated(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -106,6 +106,7 @@ class UpgradesTransferCurrencies extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -87,6 +87,7 @@ class UpgradesVariousCurrencyInformation extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -64,6 +64,7 @@ class UpgradesWebhooks extends Command
private function isExecuted(): bool
{
$configVar = app('fireflyconfig')->get(self::CONFIG_NAME, false);
return (bool)$configVar?->data;
}

View File

@@ -64,7 +64,6 @@ trait VerifiesAccessToken
/**
* Returns false when given token does not match given user token.
*
*/
protected function verifyAccessToken(): bool
{

View File

@@ -49,6 +49,7 @@ use Symfony\Component\HttpKernel\Exception\HttpException;
use Symfony\Component\HttpKernel\Exception\MethodNotAllowedHttpException;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use Throwable;
use function Safe\json_encode;
use function Safe\parse_url;

View File

@@ -78,7 +78,8 @@ class AccountFactory
if (!$type instanceof AccountType) {
throw new FireflyException(sprintf('Cannot find account type "%s"', $accountType));
}
/** @var Account|null $return */
/** @var null|Account $return */
$return = $this->user->accounts->where('account_type_id', $type->id)->where('name', $accountName)->first();
if (null === $return) {

View File

@@ -36,6 +36,7 @@ use FireflyIII\Repositories\PiggyBank\PiggyBankRepositoryInterface;
use FireflyIII\User;
use Illuminate\Database\QueryException;
use Illuminate\Support\Facades\Log;
use function Safe\json_encode;
/**

View File

@@ -55,6 +55,7 @@ use FireflyIII\Validation\AccountValidator;
use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Log;
use JsonException;
use function Safe\json_encode;
/**
@@ -342,8 +343,6 @@ class TransactionJournalFactory
/**
* If this transaction already exists, throw an error.
*
* @param string $hash
*
* @throws DuplicateTransactionException
* @throws JsonException
* @throws \Safe\Exceptions\JsonException
@@ -480,8 +479,6 @@ class TransactionJournalFactory
};
}
/**
*/
private function getCurrency(?TransactionCurrency $currency, Account $account): TransactionCurrency
{
Log::debug(sprintf('Now in getCurrency(#%d, "%s")', $currency?->id, $account->name));

View File

@@ -33,6 +33,7 @@ use FireflyIII\Notifications\User\SubscriptionsOverdueReminder;
use FireflyIII\Support\Facades\Preferences;
use Illuminate\Support\Facades\Log;
use Illuminate\Support\Facades\Notification;
use function Safe\json_encode;
/**

View File

@@ -164,7 +164,6 @@ class UserEventHandler
/**
* Set the demo user back to English.
*
*/
public function demoUserBackToEnglish(Login $event): void
{
@@ -181,8 +180,6 @@ class UserEventHandler
}
}
/**
*/
public function notifyNewIPAddress(DetectedNewIPAddress $event): void
{
$user = $event->user;
@@ -445,8 +442,6 @@ class UserEventHandler
Log::debug(sprintf('If you see no errors above this line, test notification was sent over channel "%s"', $event->channel));
}
/**
*/
public function storeUserIPAddress(ActuallyLoggedIn $event): void
{
app('log')->debug('Now in storeUserIPAddress');

View File

@@ -44,8 +44,6 @@ class VersionCheckEventHandler
/**
* Checks with GitHub to see if there is a new version.
*
* @param RequestedVersionCheckStatus $event
*
* @throws ContainerExceptionInterface
* @throws FireflyException
* @throws NotFoundExceptionInterface
@@ -93,8 +91,6 @@ class VersionCheckEventHandler
}
/**
* @param RequestedVersionCheckStatus $event
*
* @throws FireflyException
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface

View File

@@ -38,11 +38,13 @@ use Safe\Exceptions\FileinfoException;
use Safe\Exceptions\FilesystemException;
use Safe\Exceptions\StringsException;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use function Safe\fclose;
use function Safe\finfo_open;
use function Safe\fwrite;
use function Safe\md5_file;
use function Safe\tmpfile;
use const DIRECTORY_SEPARATOR;
/**
@@ -220,10 +222,6 @@ class AttachmentHelper implements AttachmentHelperInterface
/**
* Process the upload of a file.
*
* @param UploadedFile $file
* @param Model $model
*
* @return Attachment|null
* @throws StringsException
*/
protected function processFile(UploadedFile $file, Model $model): ?Attachment

View File

@@ -36,6 +36,7 @@ use Illuminate\Database\Eloquent\Builder as EloquentBuilder;
use Illuminate\Database\Query\JoinClause;
use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Log;
use function Safe\json_encode;
/**

View File

@@ -48,6 +48,7 @@ use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Log;
use Override;
use Safe\Exceptions\JsonException;
use function Safe\json_decode;
/**
@@ -564,9 +565,6 @@ class GroupCollector implements GroupCollectorInterface
}
/**
* @param TransactionJournal $augumentedJournal
*
* @return array
* @throws FireflyException
* @throws JsonException
*/

View File

@@ -64,9 +64,8 @@ class FiscalHelper implements FiscalHelperInterface
}
/**
* @param Carbon $date
*
* @return Carbon date object
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -28,6 +28,7 @@ use Carbon\Carbon;
use FireflyIII\Exceptions\FireflyException;
use FireflyIII\Models\WebhookMessage;
use JsonException;
use function Safe\json_encode;
/**

View File

@@ -132,8 +132,6 @@ class CreateController extends Controller
/**
* Store the new account.
*
* @param AccountFormRequest $request
*
* @return Redirector|RedirectResponse
*
* @throws ContainerExceptionInterface

View File

@@ -67,9 +67,6 @@ class IndexController extends Controller
}
/**
* @param Request $request
* @param string $objectType
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
@@ -141,9 +138,6 @@ class IndexController extends Controller
/**
* Show list of accounts.
*
* @param Request $request
* @param string $objectType
*
* @return Factory|View
*
* @throws ContainerExceptionInterface

View File

@@ -78,11 +78,6 @@ class ShowController extends Controller
/**
* Show an account.
*
* @param Request $request
* @param Account $account
* @param Carbon|null $start
* @param Carbon|null $end
*
* @return Factory|Redirector|RedirectResponse|View
*
* @throws ContainerExceptionInterface
@@ -202,9 +197,6 @@ class ShowController extends Controller
/**
* Show an account.
*
* @param Request $request
* @param Account $account
*
* @return Factory|Redirector|RedirectResponse|View
*
* @throws ContainerExceptionInterface

View File

@@ -49,6 +49,7 @@ class HomeController extends Controller
* Index of the admin.
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -154,6 +154,7 @@ class UserController extends Controller
* Show index of user manager.
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws FireflyException
* @throws NotFoundExceptionInterface

View File

@@ -36,6 +36,7 @@ use Illuminate\View\View;
use Psr\Container\ContainerExceptionInterface;
use Psr\Container\NotFoundExceptionInterface;
use Safe\Exceptions\UrlException;
use function Safe\parse_url;
/**
@@ -61,10 +62,8 @@ class ForgotPasswordController extends Controller
/**
* Send a reset link to the given user.
*
* @param Request $request
* @param UserRepositoryInterface $repository
*
* @return Factory|RedirectResponse|View
*
* @throws FireflyException
*/
public function sendResetLinkEmail(Request $request, UserRepositoryInterface $repository)

View File

@@ -221,8 +221,6 @@ class LoginController extends Controller
/**
* Show the application's login form.
*
* @param Request $request
*
* @return Application|Factory|Redirector|RedirectResponse|View
*
* @throws FireflyException

View File

@@ -140,9 +140,6 @@ class RegisterController extends Controller
/**
* Show the application registration form if the invitation code is valid.
*
* @param Request $request
* @param string $code
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
@@ -177,8 +174,6 @@ class RegisterController extends Controller
/**
* Show the application registration form.
*
* @param Request|null $request
*
* @return Factory|View
*
* @throws ContainerExceptionInterface

View File

@@ -114,7 +114,6 @@ class ResetPasswordController extends Controller
*
* If no token is present, display the link request form.
*
* @param Request $request
* @param null $token
*
* @return Factory|View

View File

@@ -61,9 +61,8 @@ class TwoFactorController extends Controller
}
/**
* @param Request $request
*
* @return Redirector|RedirectResponse
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -147,8 +147,6 @@ class IndexController extends Controller
return view('bills.index', compact('bills', 'sums', 'total', 'totals', 'today'));
}
/**
*/
private function getSums(array $bills): array
{
$sums = [];

View File

@@ -115,10 +115,8 @@ class ShowController extends Controller
/**
* Show a bill.
*
* @param Request $request
* @param Bill $bill
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -75,10 +75,6 @@ class ShowController extends Controller
/**
* Show transactions without a budget.
*
* @param Request $request
* @param Carbon|null $start
* @param Carbon|null $end
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
@@ -118,9 +114,8 @@ class ShowController extends Controller
/**
* Shows ALL transactions without a budget.
*
* @param Request $request
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/
@@ -147,10 +142,8 @@ class ShowController extends Controller
/**
* Show a single budget.
*
* @param Request $request
* @param Budget $budget
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/
@@ -183,10 +176,6 @@ class ShowController extends Controller
/**
* Show a single budget by a budget limit.
*
* @param Request $request
* @param Budget $budget
* @param BudgetLimit $budgetLimit
*
* @return Factory|View
*
* @throws FireflyException

View File

@@ -64,9 +64,8 @@ class IndexController extends Controller
/**
* Show all categories.
*
* @param Request $request
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -71,10 +71,6 @@ class NoCategoryController extends Controller
/**
* Show transactions without a category.
*
* @param Request $request
* @param Carbon|null $start
* @param Carbon|null $end
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
@@ -114,9 +110,8 @@ class NoCategoryController extends Controller
/**
* Show all transactions without a category.
*
* @param Request $request
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -70,11 +70,6 @@ class ShowController extends Controller
/**
* Show a single category.
*
* @param Request $request
* @param Category $category
* @param Carbon|null $start
* @param Carbon|null $end
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
@@ -120,10 +115,8 @@ class ShowController extends Controller
/**
* Show all transactions within a category.
*
* @param Request $request
* @param Category $category
*
* @return Factory|View
*
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -45,6 +45,7 @@ use Illuminate\Http\JsonResponse;
use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Log;
use Safe\Exceptions\JsonException;
use function Safe\json_encode;
/**
@@ -482,11 +483,6 @@ class AccountController extends Controller
/**
* Shows overview of account during a single period.
*
* @param Account $account
* @param Carbon $start
* @param Carbon $end
*
* @return JsonResponse
* @throws FireflyException
* @throws JsonException
*/

View File

@@ -66,7 +66,6 @@ class CategoryController extends Controller
/**
* Show an overview for a category for all time, per month/week/year.
* TODO test method, for category refactor.
*
*/
public function all(Category $category): JsonResponse
{
@@ -256,10 +255,6 @@ class CategoryController extends Controller
* Chart for a specific period.
* TODO test me, for category refactor.
*
* @param Category $category
* @param Carbon $date
*
* @return JsonResponse
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/

View File

@@ -57,7 +57,6 @@ class PiggyBankController extends Controller
* Shows the piggy bank history.
*
* TODO this chart is not multi currency aware.
*
*/
public function history(PiggyBankRepositoryInterface $repository, PiggyBank $piggyBank): JsonResponse
{

View File

@@ -38,6 +38,7 @@ use Illuminate\Support\Facades\Config;
use Illuminate\Support\Facades\Log;
use Illuminate\Support\Facades\Route;
use Illuminate\Support\Facades\View;
use function Safe\ini_get;
use function Safe\realpath;

View File

@@ -51,8 +51,10 @@ use Illuminate\View\View;
use Monolog\Handler\RotatingFileHandler;
use Safe\Exceptions\FilesystemException;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use function Safe\file_get_contents;
use function Safe\ini_get;
use const PHP_INT_SIZE;
use const PHP_SAPI;

View File

@@ -92,10 +92,6 @@ class JavascriptController extends Controller
/**
* Show some common variables to be used in scripts.
*
* @param Request $request
* @param AccountRepositoryInterface $repository
*
* @return Response
* @throws FireflyException
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface

View File

@@ -87,7 +87,6 @@ class IntroController extends Controller
/**
* Enable the boxes for a specific page again.
*
*/
public function postEnable(string $route, ?string $specialPage = null): JsonResponse
{
@@ -106,7 +105,6 @@ class IntroController extends Controller
/**
* Set that you saw them.
*
*/
public function postFinished(string $route, ?string $specialPage = null): JsonResponse
{

Some files were not shown because too many files have changed in this diff Show More