diff --git a/app/Http/Controllers/Account/ReconcileController.php b/app/Http/Controllers/Account/ReconcileController.php
index 4232e35712..2c1772adc0 100644
--- a/app/Http/Controllers/Account/ReconcileController.php
+++ b/app/Http/Controllers/Account/ReconcileController.php
@@ -164,6 +164,7 @@ class ReconcileController extends Controller
* @param Carbon $end
*
* @return RedirectResponse|Redirector
+ * @throws DuplicateTransactionException
*/
public function submit(ReconciliationStoreRequest $request, Account $account, Carbon $start, Carbon $end)
{
diff --git a/app/Http/Controllers/Admin/ConfigurationController.php b/app/Http/Controllers/Admin/ConfigurationController.php
index f3c17ce1b0..bcd31ac1ee 100644
--- a/app/Http/Controllers/Admin/ConfigurationController.php
+++ b/app/Http/Controllers/Admin/ConfigurationController.php
@@ -18,7 +18,6 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
-/** @noinspection PhpUndefinedClassInspection */
declare(strict_types=1);
namespace FireflyIII\Http\Controllers\Admin;
@@ -60,6 +59,7 @@ class ConfigurationController extends Controller
* Show configuration index.
*
* @return Factory|View
+ * @throws \FireflyIII\Exceptions\FireflyException
*/
public function index()
{
diff --git a/app/Http/Controllers/Admin/HomeController.php b/app/Http/Controllers/Admin/HomeController.php
index fc921db193..c4da989f2c 100644
--- a/app/Http/Controllers/Admin/HomeController.php
+++ b/app/Http/Controllers/Admin/HomeController.php
@@ -60,7 +60,7 @@ class HomeController extends Controller
$title = (string)trans('firefly.administration');
$mainTitleIcon = 'fa-hand-spock-o';
$email = auth()->user()->email;
- $pref = app('preferences')->get('remote_guard_alt_email', null);
+ $pref = app('preferences')->get('remote_guard_alt_email');
if (null !== $pref && is_string($pref->data)) {
$email = $pref->data;
}
diff --git a/app/Http/Controllers/Admin/UpdateController.php b/app/Http/Controllers/Admin/UpdateController.php
index 51020ffef3..1ef75943e1 100644
--- a/app/Http/Controllers/Admin/UpdateController.php
+++ b/app/Http/Controllers/Admin/UpdateController.php
@@ -18,7 +18,6 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
-/** @noinspection PhpMethodParametersCountMismatchInspection */
declare(strict_types=1);
namespace FireflyIII\Http\Controllers\Admin;
diff --git a/app/Http/Controllers/Auth/ConfirmPasswordController.php b/app/Http/Controllers/Auth/ConfirmPasswordController.php
index 8aa2052f19..370dba8d05 100644
--- a/app/Http/Controllers/Auth/ConfirmPasswordController.php
+++ b/app/Http/Controllers/Auth/ConfirmPasswordController.php
@@ -57,7 +57,7 @@ class ConfirmPasswordController extends Controller
/**
* Create a new controller instance.
*
- * @return void
+ * @throws FireflyException
*/
public function __construct()
{
diff --git a/app/Http/Controllers/Auth/ForgotPasswordController.php b/app/Http/Controllers/Auth/ForgotPasswordController.php
index 01372e02ef..24c302777a 100644
--- a/app/Http/Controllers/Auth/ForgotPasswordController.php
+++ b/app/Http/Controllers/Auth/ForgotPasswordController.php
@@ -18,7 +18,6 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
-/** @noinspection PhpDynamicAsStaticMethodCallInspection */
declare(strict_types=1);
namespace FireflyIII\Http\Controllers\Auth;
@@ -111,6 +110,7 @@ class ForgotPasswordController extends Controller
* @codeCoverageIgnore
*
* @return Factory|View
+ * @throws FireflyException
*/
public function showLinkRequestForm()
{
diff --git a/app/Http/Controllers/Auth/LoginController.php b/app/Http/Controllers/Auth/LoginController.php
index 0295bc0388..16e15c6726 100644
--- a/app/Http/Controllers/Auth/LoginController.php
+++ b/app/Http/Controllers/Auth/LoginController.php
@@ -73,14 +73,14 @@ class LoginController extends Controller
*
* @param Request $request
*
- * @return RedirectResponse|\Illuminate\Http\Response|JsonResponse
+ * @return JsonResponse|RedirectResponse
*
* @throws ValidationException
*/
public function login(Request $request)
{
Log::channel('audit')->info(sprintf('User is trying to login using "%s"', $request->get('email')));
- Log::info(sprintf('User is trying to login.'));
+ Log::info('User is trying to login.');
if ('ldap' === config('auth.providers.users.driver')) {
/** @var Adldap\Connections\Provider $provider */
Adldap::getProvider('default'); // @phpstan-ignore-line
@@ -161,7 +161,7 @@ class LoginController extends Controller
*
* @param Request $request
*
- * @return Response
+ * @return void
*
* @throws ValidationException
*/
@@ -180,7 +180,10 @@ class LoginController extends Controller
/**
* Show the application's login form.
*
+ * @param Request $request
+ *
* @return Factory|\Illuminate\Http\Response|View
+ * @throws \FireflyIII\Exceptions\FireflyException
*/
public function showLoginForm(Request $request)
{
diff --git a/app/Http/Controllers/Auth/RegisterController.php b/app/Http/Controllers/Auth/RegisterController.php
index 9a0f946d97..b8e3e916c7 100644
--- a/app/Http/Controllers/Auth/RegisterController.php
+++ b/app/Http/Controllers/Auth/RegisterController.php
@@ -18,7 +18,6 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
-/** @noinspection PhpDynamicAsStaticMethodCallInspection */
declare(strict_types=1);
namespace FireflyIII\Http\Controllers\Auth;
@@ -78,6 +77,8 @@ class RegisterController extends Controller
* @param Request $request
*
* @return Factory|RedirectResponse|Redirector|View
+ * @throws FireflyException
+ * @throws \Illuminate\Validation\ValidationException
*/
public function register(Request $request)
{
@@ -123,6 +124,7 @@ class RegisterController extends Controller
* @param Request $request
*
* @return Factory|View
+ * @throws FireflyException
*/
public function showRegistrationForm(Request $request)
{
diff --git a/app/Http/Controllers/Auth/ResetPasswordController.php b/app/Http/Controllers/Auth/ResetPasswordController.php
index 99a4a456b1..cfef605eb6 100644
--- a/app/Http/Controllers/Auth/ResetPasswordController.php
+++ b/app/Http/Controllers/Auth/ResetPasswordController.php
@@ -18,7 +18,6 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
-/** @noinspection PhpDynamicAsStaticMethodCallInspection */
declare(strict_types=1);
namespace FireflyIII\Http\Controllers\Auth;
@@ -120,10 +119,11 @@ class ResetPasswordController extends Controller
*
* If no token is present, display the link request form.
*
- * @param Request $request
- * @param string|null $token
+ * @param Request $request
+ * @param null $token
*
* @return Factory|View
+ * @throws FireflyException
*/
public function showResetForm(Request $request, $token = null)
{
diff --git a/app/Http/Controllers/Auth/TwoFactorController.php b/app/Http/Controllers/Auth/TwoFactorController.php
index 453725b718..7b7f104223 100644
--- a/app/Http/Controllers/Auth/TwoFactorController.php
+++ b/app/Http/Controllers/Auth/TwoFactorController.php
@@ -38,7 +38,7 @@ class TwoFactorController extends Controller
/**
* What to do if 2FA lost?
*
- * @return mixed
+ * @return \Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View
*/
public function lostTwoFactor()
{
diff --git a/app/Http/Controllers/Bill/CreateController.php b/app/Http/Controllers/Bill/CreateController.php
index 8efdbc45b5..17d1dcde7a 100644
--- a/app/Http/Controllers/Bill/CreateController.php
+++ b/app/Http/Controllers/Bill/CreateController.php
@@ -70,7 +70,7 @@ class CreateController extends Controller
*
* @param Request $request
*
- * @return Application|Factory|View
+ * @return Factory|\Illuminate\Contracts\View\View
*/
public function create(Request $request)
{
diff --git a/app/Http/Controllers/Bill/EditController.php b/app/Http/Controllers/Bill/EditController.php
index 108e5bcf49..f713d87dde 100644
--- a/app/Http/Controllers/Bill/EditController.php
+++ b/app/Http/Controllers/Bill/EditController.php
@@ -70,7 +70,7 @@ class EditController extends Controller
* @param Request $request
* @param Bill $bill
*
- * @return Application|Factory|View
+ * @return Factory|\Illuminate\Contracts\View\View
*/
public function edit(Request $request, Bill $bill)
{
diff --git a/app/Http/Controllers/Bill/IndexController.php b/app/Http/Controllers/Bill/IndexController.php
index 1e6c59aca7..7f7d472c3e 100644
--- a/app/Http/Controllers/Bill/IndexController.php
+++ b/app/Http/Controllers/Bill/IndexController.php
@@ -116,7 +116,7 @@ class IndexController extends Controller
}
$current = $array['pay_dates'][0] ?? null;
if (null !== $current && !$nextExpectedMatch->isToday()) {
- $currentExpectedMatch = Carbon::createFromFormat(Carbon::ATOM, $current);
+ $currentExpectedMatch = Carbon::createFromFormat('Y-m-d\TH:i:sP', $current);
$array['next_expected_match_diff'] = $currentExpectedMatch->diffForHumans(today(), Carbon::DIFF_RELATIVE_TO_NOW);
}
@@ -195,7 +195,7 @@ class IndexController extends Controller
$avg = bcdiv(bcadd((string)$bill['amount_min'], (string)$bill['amount_max']), '2');
Log::debug(sprintf('Amount per period for bill #%d "%s"', $bill['id'], $bill['name']));
- Log::debug(sprintf(sprintf('Average is %s', $avg)));
+ Log::debug(sprintf('Average is %s', $avg));
// calculate amount per year:
$multiplies = [
'yearly' => '1',
diff --git a/app/Http/Controllers/Bill/ShowController.php b/app/Http/Controllers/Bill/ShowController.php
index 0c3f0ffe07..6a871b05a3 100644
--- a/app/Http/Controllers/Bill/ShowController.php
+++ b/app/Http/Controllers/Bill/ShowController.php
@@ -80,7 +80,6 @@ class ShowController extends Controller
* @param Bill $bill
*
* @return RedirectResponse|Redirector
- * @throws FireflyException
*/
public function rescan(Request $request, Bill $bill)
{
diff --git a/app/Http/Controllers/Budget/BudgetLimitController.php b/app/Http/Controllers/Budget/BudgetLimitController.php
index eaa1ec3c93..99fb420ce9 100644
--- a/app/Http/Controllers/Budget/BudgetLimitController.php
+++ b/app/Http/Controllers/Budget/BudgetLimitController.php
@@ -123,7 +123,7 @@ class BudgetLimitController extends Controller
/**
* @param Request $request
*
- * @return JsonResponse|RedirectResponse|Redirector
+ * @return JsonResponse
* @throws FireflyException
*/
public function store(Request $request)
diff --git a/app/Http/Controllers/Budget/CreateController.php b/app/Http/Controllers/Budget/CreateController.php
index 32ced8a890..03c6fd26e6 100644
--- a/app/Http/Controllers/Budget/CreateController.php
+++ b/app/Http/Controllers/Budget/CreateController.php
@@ -111,6 +111,7 @@ class CreateController extends Controller
* @param BudgetFormStoreRequest $request
*
* @return RedirectResponse
+ * @throws \FireflyIII\Exceptions\FireflyException
*/
public function store(BudgetFormStoreRequest $request): RedirectResponse
{
diff --git a/app/Http/Controllers/Category/CreateController.php b/app/Http/Controllers/Category/CreateController.php
index 024d71dc06..8ef6825105 100644
--- a/app/Http/Controllers/Category/CreateController.php
+++ b/app/Http/Controllers/Category/CreateController.php
@@ -86,6 +86,7 @@ class CreateController extends Controller
* @param CategoryFormRequest $request
*
* @return $this|RedirectResponse|Redirector
+ * @throws \FireflyIII\Exceptions\FireflyException
*/
public function store(CategoryFormRequest $request)
{
diff --git a/app/Http/Controllers/Chart/CategoryController.php b/app/Http/Controllers/Chart/CategoryController.php
index 4653e88809..a93fec10d3 100644
--- a/app/Http/Controllers/Chart/CategoryController.php
+++ b/app/Http/Controllers/Chart/CategoryController.php
@@ -168,10 +168,10 @@ class CategoryController extends Controller
/**
* Generate report chart for either with or without category.
*
- * @param Collection $accounts
- * @param Carbon $start
- * @param Carbon $end
- * @param Category $category
+ * @param Collection $accounts
+ * @param Carbon $start
+ * @param Carbon $end
+ * @param Category|null $category
*
* @return array
*/
diff --git a/app/Http/Controllers/Chart/ExpenseReportController.php b/app/Http/Controllers/Chart/ExpenseReportController.php
index b4041c0c2f..bbd289c54a 100644
--- a/app/Http/Controllers/Chart/ExpenseReportController.php
+++ b/app/Http/Controllers/Chart/ExpenseReportController.php
@@ -184,7 +184,7 @@ class ExpenseReportController extends Controller
$newSet = [];
foreach ($chartData as $key => $entry) {
if (0 === !array_sum($entry['entries'])) {
- $newSet[$key] = $chartData[$key];
+ $newSet[$key] = $entry;
}
}
if (0===count($newSet)) {
diff --git a/app/Http/Controllers/Chart/PiggyBankController.php b/app/Http/Controllers/Chart/PiggyBankController.php
index 3bf3218e97..d40c0ebd01 100644
--- a/app/Http/Controllers/Chart/PiggyBankController.php
+++ b/app/Http/Controllers/Chart/PiggyBankController.php
@@ -94,7 +94,6 @@ class PiggyBankController extends Controller
$chartData = [];
while ($oldest <= $today) {
- /** @var Collection $filtered */
$filtered = $set->filter(
function (PiggyBankEvent $event) use ($oldest) {
return $event->date->lte($oldest);
@@ -105,7 +104,6 @@ class PiggyBankController extends Controller
$chartData[$label] = $currentSum;
$oldest = app('navigation')->addPeriod($oldest, $step, 0);
}
- /** @var Collection $finalFiltered */
$finalFiltered = $set->filter(
function (PiggyBankEvent $event) use ($today) {
return $event->date->lte($today);
diff --git a/app/Http/Controllers/Export/IndexController.php b/app/Http/Controllers/Export/IndexController.php
index af0a66181f..cb7e570c4b 100644
--- a/app/Http/Controllers/Export/IndexController.php
+++ b/app/Http/Controllers/Export/IndexController.php
@@ -66,6 +66,8 @@ class IndexController extends Controller
/**
* @return LaravelResponse
* @throws CannotInsertRecord
+ * @throws \FireflyIII\Exceptions\FireflyException
+ * @throws \League\Csv\Exception
*/
public function export(): LaravelResponse
{
@@ -89,7 +91,7 @@ class IndexController extends Controller
$quoted = sprintf('"%s"', addcslashes($name, '"\\'));
// headers for CSV file.
/** @var LaravelResponse $response */
- $response = response($result['transactions'], 200);
+ $response = response($result['transactions']);
$response
->header('Content-Description', 'File Transfer')
->header('Content-Type', 'text/x-csv')
diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php
index b2f066d738..cff4d19f0c 100644
--- a/app/Http/Controllers/HomeController.php
+++ b/app/Http/Controllers/HomeController.php
@@ -102,8 +102,7 @@ class HomeController extends Controller
*
* @param AccountRepositoryInterface $repository
*
- * @return Factory|RedirectResponse|Redirector|View
- * @throws Exception
+ * @return mixed
*/
public function index(AccountRepositoryInterface $repository): mixed
{
diff --git a/app/Http/Controllers/Json/BudgetController.php b/app/Http/Controllers/Json/BudgetController.php
index 28ed024372..523463a5eb 100644
--- a/app/Http/Controllers/Json/BudgetController.php
+++ b/app/Http/Controllers/Json/BudgetController.php
@@ -79,11 +79,15 @@ class BudgetController extends Controller
}
/**
+ * @param TransactionCurrency $currency
+ * @param Carbon $start
+ * @param Carbon $end
+ *
* @return JsonResponse
*/
public function getBudgetInformation(TransactionCurrency $currency, Carbon $start, Carbon $end): JsonResponse
{
- $budgeted = $this->blRepository->budgeted($start, $end, $currency,);
+ $budgeted = $this->blRepository->budgeted($start, $end, $currency);
$availableBudget = $this->abRepository->getByCurrencyDate($start, $end, $currency);
$available = '0';
$percentage = '0';
diff --git a/app/Http/Controllers/Json/ReconcileController.php b/app/Http/Controllers/Json/ReconcileController.php
index 598def4f96..66ea1b5256 100644
--- a/app/Http/Controllers/Json/ReconcileController.php
+++ b/app/Http/Controllers/Json/ReconcileController.php
@@ -214,7 +214,7 @@ class ReconcileController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return mixed
+ * @return JsonResponse
*
*/
public function transactions(Account $account, Carbon $start, Carbon $end)
diff --git a/app/Http/Controllers/Json/RecurrenceController.php b/app/Http/Controllers/Json/RecurrenceController.php
index 6fc636fd32..bdd6ee25d4 100644
--- a/app/Http/Controllers/Json/RecurrenceController.php
+++ b/app/Http/Controllers/Json/RecurrenceController.php
@@ -165,15 +165,15 @@ class RecurrenceController extends Controller
$yearly = sprintf('yearly,%s', $date->format('Y-m-d'));
$yearlyDate = $date->formatLocalized((string)trans('config.month_and_day_no_year', [], $locale));
$result = [
- 'daily' => ['label' => (string)trans('firefly.recurring_daily'), 'selected' => 0 === strpos($preSelected, 'daily')],
+ 'daily' => ['label' => (string)trans('firefly.recurring_daily'), 'selected' => str_starts_with($preSelected, 'daily')],
$weekly => ['label' => (string)trans('firefly.recurring_weekly', ['weekday' => $dayOfWeek]),
- 'selected' => 0 === strpos($preSelected, 'weekly')],
+ 'selected' => str_starts_with($preSelected, 'weekly')],
$monthly => ['label' => (string)trans('firefly.recurring_monthly', ['dayOfMonth' => $date->day]),
- 'selected' => 0 === strpos($preSelected, 'monthly')],
+ 'selected' => str_starts_with($preSelected, 'monthly')],
$ndom => ['label' => (string)trans('firefly.recurring_ndom', ['weekday' => $dayOfWeek, 'dayOfMonth' => $date->weekOfMonth]),
- 'selected' => 0 === strpos($preSelected, 'ndom')],
+ 'selected' => str_starts_with($preSelected, 'ndom')],
$yearly => ['label' => (string)trans('firefly.recurring_yearly', ['date' => $yearlyDate]),
- 'selected' => 0 === strpos($preSelected, 'yearly')],
+ 'selected' => str_starts_with($preSelected, 'yearly')],
];
}
Log::debug('Dropdown is', $result);
diff --git a/app/Http/Controllers/NewUserController.php b/app/Http/Controllers/NewUserController.php
index 8d8af05fa4..ab85cf8c29 100644
--- a/app/Http/Controllers/NewUserController.php
+++ b/app/Http/Controllers/NewUserController.php
@@ -27,8 +27,10 @@ use FireflyIII\Models\AccountType;
use FireflyIII\Repositories\Account\AccountRepositoryInterface;
use FireflyIII\Repositories\Currency\CurrencyRepositoryInterface;
use FireflyIII\Support\Http\Controllers\CreateStuff;
+use Illuminate\Contracts\View\Factory;
use Illuminate\Http\RedirectResponse;
use Illuminate\Routing\Redirector;
+use Illuminate\View\View;
/**
* Class NewUserController.
@@ -58,7 +60,7 @@ class NewUserController extends Controller
/**
* Form the user gets when he has no data in the system.
*
- * @return RedirectResponse|Redirector|\Illuminate\Contracts\View\Factory|\Illuminate\View\View
+ * @return RedirectResponse|Redirector|Factory|View
*/
public function index()
{
diff --git a/app/Http/Controllers/ObjectGroup/DeleteController.php b/app/Http/Controllers/ObjectGroup/DeleteController.php
index c5fa6c7f85..e5efc8b58c 100644
--- a/app/Http/Controllers/ObjectGroup/DeleteController.php
+++ b/app/Http/Controllers/ObjectGroup/DeleteController.php
@@ -61,6 +61,8 @@ class DeleteController extends Controller
* Delete a piggy bank.
*
* @param ObjectGroup $objectGroup
+ *
+ * @return \Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View
*/
public function delete(ObjectGroup $objectGroup)
{
@@ -77,6 +79,7 @@ class DeleteController extends Controller
* Destroy the piggy bank.
*
* @param ObjectGroup $objectGroup
+ * @return RedirectResponse
*/
public function destroy(ObjectGroup $objectGroup): RedirectResponse
{
diff --git a/app/Http/Controllers/ObjectGroup/EditController.php b/app/Http/Controllers/ObjectGroup/EditController.php
index f83b75541d..397dfc0437 100644
--- a/app/Http/Controllers/ObjectGroup/EditController.php
+++ b/app/Http/Controllers/ObjectGroup/EditController.php
@@ -61,6 +61,8 @@ class EditController extends Controller
* Edit an object group.
*
* @param ObjectGroup $objectGroup
+ *
+ * @return \Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View
*/
public function edit(ObjectGroup $objectGroup)
{
@@ -80,6 +82,7 @@ class EditController extends Controller
*
* @param ObjectGroupFormRequest $request
* @param ObjectGroup $objectGroup
+ * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector
*/
public function update(ObjectGroupFormRequest $request, ObjectGroup $objectGroup)
{
diff --git a/app/Http/Controllers/ObjectGroup/IndexController.php b/app/Http/Controllers/ObjectGroup/IndexController.php
index 59baa17e7c..dafa324fb9 100644
--- a/app/Http/Controllers/ObjectGroup/IndexController.php
+++ b/app/Http/Controllers/ObjectGroup/IndexController.php
@@ -62,7 +62,7 @@ class IndexController extends Controller
}
/**
- * @return Application|Factory|View
+ * @return Factory|\Illuminate\Contracts\View\View
*/
public function index()
{
@@ -75,7 +75,10 @@ class IndexController extends Controller
}
/**
+ * @param Request $request
* @param ObjectGroup $objectGroup
+ *
+ * @return \Illuminate\Http\JsonResponse
*/
public function setOrder(Request $request, ObjectGroup $objectGroup)
{
diff --git a/app/Http/Controllers/PiggyBank/CreateController.php b/app/Http/Controllers/PiggyBank/CreateController.php
index daf969a5ce..7d888b0f75 100644
--- a/app/Http/Controllers/PiggyBank/CreateController.php
+++ b/app/Http/Controllers/PiggyBank/CreateController.php
@@ -88,6 +88,7 @@ class CreateController extends Controller
* @param PiggyBankStoreRequest $request
*
* @return RedirectResponse|Redirector
+ * @throws \FireflyIII\Exceptions\FireflyException
*/
public function store(PiggyBankStoreRequest $request)
{
diff --git a/app/Http/Controllers/ProfileController.php b/app/Http/Controllers/ProfileController.php
index 7d3f9ecbf8..a6276b9bf2 100644
--- a/app/Http/Controllers/ProfileController.php
+++ b/app/Http/Controllers/ProfileController.php
@@ -39,6 +39,7 @@ use FireflyIII\User;
use Google2FA;
use Hash;
use Illuminate\Contracts\Auth\Guard;
+use Illuminate\Contracts\Foundation\Application;
use Illuminate\Contracts\View\Factory;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
@@ -105,7 +106,8 @@ class ProfileController extends Controller
/**
* @param Request $request
*
- * @return \Illuminate\Contracts\Foundation\Application|RedirectResponse|Redirector
+ * @return Application|RedirectResponse|Redirector
+ * @throws \Illuminate\Auth\AuthenticationException
*/
public function postLogoutOtherSessions(Request $request)
{
@@ -181,6 +183,9 @@ class ProfileController extends Controller
* @param Request $request
*
* @return Factory|View
+ * @throws \PragmaRX\Google2FA\Exceptions\IncompatibleWithGoogleAuthenticatorException
+ * @throws \PragmaRX\Google2FA\Exceptions\InvalidCharactersException
+ * @throws \PragmaRX\Google2FA\Exceptions\SecretKeyTooShortException
*/
public function code(Request $request)
{
@@ -273,7 +278,7 @@ class ProfileController extends Controller
*
* @param Request $request
*
- * @return \Illuminate\Contracts\Foundation\Application|RedirectResponse|Redirector
+ * @return Application|RedirectResponse|Redirector
*/
public function deleteAccount(Request $request)
{
@@ -347,6 +352,7 @@ class ProfileController extends Controller
* Index for profile.
*
* @return Factory|View
+ * @throws FireflyException
*/
public function index()
{
@@ -367,7 +373,7 @@ class ProfileController extends Controller
$repository->createPersonalAccessClient(null, config('app.name') . ' Personal Access Client', 'http://localhost');
}
- $accessToken = app('preferences')->get('access_token', null);
+ $accessToken = app('preferences')->get('access_token');
if (null === $accessToken) {
$token = $user->generateAccessToken();
$accessToken = app('preferences')->set('access_token', $token);
@@ -490,7 +496,6 @@ class ProfileController extends Controller
return redirect(route('profile.index'));
}
- /** @noinspection PhpUnusedParameterInspection */
/**
* Submit 2FA for the first time.
*
@@ -570,7 +575,10 @@ class ProfileController extends Controller
/**
* Regenerate access token.
*
+ * @param Request $request
+ *
* @return RedirectResponse|Redirector
+ * @throws FireflyException
*/
public function regenerate(Request $request)
{
diff --git a/app/Http/Controllers/Recurring/CreateController.php b/app/Http/Controllers/Recurring/CreateController.php
index cbc21db8fe..d0455c2d48 100644
--- a/app/Http/Controllers/Recurring/CreateController.php
+++ b/app/Http/Controllers/Recurring/CreateController.php
@@ -122,6 +122,8 @@ class CreateController extends Controller
/**
* @param Request $request
* @param TransactionJournal $journal
+ *
+ * @return Factory|\Illuminate\Contracts\View\View
*/
public function createFromJournal(Request $request, TransactionJournal $journal)
{
@@ -214,6 +216,7 @@ class CreateController extends Controller
* @param RecurrenceFormRequest $request
*
* @return RedirectResponse|Redirector
+ * @throws FireflyException
*/
public function store(RecurrenceFormRequest $request)
{
diff --git a/app/Http/Controllers/Recurring/IndexController.php b/app/Http/Controllers/Recurring/IndexController.php
index c385b8ec22..7a73e0eb18 100644
--- a/app/Http/Controllers/Recurring/IndexController.php
+++ b/app/Http/Controllers/Recurring/IndexController.php
@@ -18,7 +18,6 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
-/** @noinspection PhpMethodParametersCountMismatchInspection */
declare(strict_types=1);
namespace FireflyIII\Http\Controllers\Recurring;
diff --git a/app/Http/Controllers/Report/BalanceController.php b/app/Http/Controllers/Report/BalanceController.php
index 88f79205e7..11c04f0cf6 100644
--- a/app/Http/Controllers/Report/BalanceController.php
+++ b/app/Http/Controllers/Report/BalanceController.php
@@ -64,7 +64,7 @@ class BalanceController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return mixed|string
+ * @return string
*/
public function general(Collection $accounts, Carbon $start, Carbon $end)
{
diff --git a/app/Http/Controllers/Report/BillController.php b/app/Http/Controllers/Report/BillController.php
index 0c14c605ac..6663b071ae 100644
--- a/app/Http/Controllers/Report/BillController.php
+++ b/app/Http/Controllers/Report/BillController.php
@@ -40,6 +40,9 @@ class BillController extends Controller
* @param Collection $accounts
* @param Carbon $start
* @param Carbon $end
+ *
+ * @return mixed|string
+ * @throws \JsonException
*/
public function overview(Collection $accounts, Carbon $start, Carbon $end)
{ // chart properties for cache:
diff --git a/app/Http/Controllers/Report/BudgetController.php b/app/Http/Controllers/Report/BudgetController.php
index 31efb8aee7..b0c17a6ef5 100644
--- a/app/Http/Controllers/Report/BudgetController.php
+++ b/app/Http/Controllers/Report/BudgetController.php
@@ -160,7 +160,7 @@ class BudgetController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function avgExpenses(Collection $accounts, Collection $budgets, Carbon $start, Carbon $end)
{
@@ -281,7 +281,7 @@ class BudgetController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return mixed|string
+ * @return string
*/
public function general(Collection $accounts, Carbon $start, Carbon $end)
{
@@ -369,7 +369,7 @@ class BudgetController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function topExpenses(Collection $accounts, Collection $budgets, Carbon $start, Carbon $end)
{
diff --git a/app/Http/Controllers/Report/CategoryController.php b/app/Http/Controllers/Report/CategoryController.php
index 6fb33635bc..17b2b7e0f9 100644
--- a/app/Http/Controllers/Report/CategoryController.php
+++ b/app/Http/Controllers/Report/CategoryController.php
@@ -274,7 +274,7 @@ class CategoryController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function avgExpenses(Collection $accounts, Collection $categories, Carbon $start, Carbon $end)
{
@@ -326,7 +326,7 @@ class CategoryController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function avgIncome(Collection $accounts, Collection $categories, Carbon $start, Carbon $end)
{
@@ -685,7 +685,7 @@ class CategoryController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function topExpenses(Collection $accounts, Collection $categories, Carbon $start, Carbon $end)
{
@@ -735,7 +735,7 @@ class CategoryController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function topIncome(Collection $accounts, Collection $categories, Carbon $start, Carbon $end)
{
diff --git a/app/Http/Controllers/Report/DoubleController.php b/app/Http/Controllers/Report/DoubleController.php
index 4436c6f3a6..cb1d8e90dd 100644
--- a/app/Http/Controllers/Report/DoubleController.php
+++ b/app/Http/Controllers/Report/DoubleController.php
@@ -74,7 +74,7 @@ class DoubleController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function avgExpenses(Collection $accounts, Collection $doubles, Carbon $start, Carbon $end)
{
@@ -126,7 +126,7 @@ class DoubleController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function avgIncome(Collection $accounts, Collection $doubles, Carbon $start, Carbon $end)
{
@@ -422,7 +422,7 @@ class DoubleController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function topExpenses(Collection $accounts, Collection $doubles, Carbon $start, Carbon $end)
{
@@ -472,7 +472,7 @@ class DoubleController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function topIncome(Collection $accounts, Collection $doubles, Carbon $start, Carbon $end)
{
diff --git a/app/Http/Controllers/Report/TagController.php b/app/Http/Controllers/Report/TagController.php
index 94bc705e7c..a44326848b 100644
--- a/app/Http/Controllers/Report/TagController.php
+++ b/app/Http/Controllers/Report/TagController.php
@@ -268,7 +268,7 @@ class TagController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function avgExpenses(Collection $accounts, Collection $tags, Carbon $start, Carbon $end)
{
@@ -320,7 +320,7 @@ class TagController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function avgIncome(Collection $accounts, Collection $tags, Carbon $start, Carbon $end)
{
@@ -480,7 +480,7 @@ class TagController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function topExpenses(Collection $accounts, Collection $tags, Carbon $start, Carbon $end)
{
@@ -530,7 +530,7 @@ class TagController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return array|string
+ * @return string
*/
public function topIncome(Collection $accounts, Collection $tags, Carbon $start, Carbon $end)
{
diff --git a/app/Http/Controllers/ReportController.php b/app/Http/Controllers/ReportController.php
index 6fe28b026b..174ab8ac34 100644
--- a/app/Http/Controllers/ReportController.php
+++ b/app/Http/Controllers/ReportController.php
@@ -227,7 +227,7 @@ class ReportController extends Controller
* @param Carbon $start
* @param Carbon $end
*
- * @return Factory|View|string
+ * @return string
* @throws FireflyException
*/
public function doubleReport(Collection $accounts, Collection $expense, Carbon $start, Carbon $end)
@@ -299,7 +299,7 @@ class ReportController extends Controller
*
* @param string $reportType
*
- * @return mixed
+ * @return \Illuminate\Http\JsonResponse
*
*/
public function options(string $reportType)
diff --git a/app/Http/Controllers/Rule/CreateController.php b/app/Http/Controllers/Rule/CreateController.php
index e6f675539b..7a51740b24 100644
--- a/app/Http/Controllers/Rule/CreateController.php
+++ b/app/Http/Controllers/Rule/CreateController.php
@@ -187,6 +187,8 @@ class CreateController extends Controller
/**
* @param Request $request
* @param TransactionJournal $journal
+ *
+ * @return Factory|\Illuminate\Contracts\View\View
*/
public function createFromJournal(Request $request, TransactionJournal $journal)
{
@@ -239,7 +241,6 @@ class CreateController extends Controller
*/
public function duplicate(Rule $rule): RedirectResponse
{
- /** @var Rule $newRule */
$newRule = $this->ruleRepos->duplicate($rule);
session()->flash('success', trans('firefly.duplicated_rule', ['title' => $rule->title, 'newTitle' => $newRule->title]));
diff --git a/app/Http/Controllers/Rule/IndexController.php b/app/Http/Controllers/Rule/IndexController.php
index 4c9d6b3a58..b680cbb134 100644
--- a/app/Http/Controllers/Rule/IndexController.php
+++ b/app/Http/Controllers/Rule/IndexController.php
@@ -99,7 +99,6 @@ class IndexController extends Controller
* @param Rule $rule
*
* @return RedirectResponse
- * @throws FireflyException
*/
public function search(Rule $rule): RedirectResponse
{
diff --git a/app/Http/Controllers/System/CronController.php b/app/Http/Controllers/System/CronController.php
index 442954d010..e75f33f836 100644
--- a/app/Http/Controllers/System/CronController.php
+++ b/app/Http/Controllers/System/CronController.php
@@ -31,7 +31,7 @@ use Log;
class CronController
{
/**
- * @return string
+ * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\Routing\ResponseFactory|\Illuminate\Http\Response
*/
public function cron()
{
diff --git a/app/Http/Controllers/TagController.php b/app/Http/Controllers/TagController.php
index e28c06a657..04271ef4a4 100644
--- a/app/Http/Controllers/TagController.php
+++ b/app/Http/Controllers/TagController.php
@@ -18,7 +18,6 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see .
*/
-/** @noinspection PhpMethodParametersCountMismatchInspection */
declare(strict_types=1);
namespace FireflyIII\Http\Controllers;
@@ -229,7 +228,7 @@ class TagController extends Controller
* @param Carbon|null $end
*
* @return Factory|View
- *
+ * @throws \FireflyIII\Exceptions\FireflyException
*/
public function show(Request $request, Tag $tag, Carbon $start = null, Carbon $end = null)
{
diff --git a/app/Http/Controllers/Transaction/BulkController.php b/app/Http/Controllers/Transaction/BulkController.php
index 18a6ec6e75..fadb350d4c 100644
--- a/app/Http/Controllers/Transaction/BulkController.php
+++ b/app/Http/Controllers/Transaction/BulkController.php
@@ -90,7 +90,7 @@ class BulkController extends Controller
*
* @param BulkEditJournalRequest $request
*
- * @return mixed
+ * @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector
*/
public function update(BulkEditJournalRequest $request)
{
diff --git a/app/Http/Controllers/Transaction/ConvertController.php b/app/Http/Controllers/Transaction/ConvertController.php
index 8e62d6c105..fa4c17bd60 100644
--- a/app/Http/Controllers/Transaction/ConvertController.php
+++ b/app/Http/Controllers/Transaction/ConvertController.php
@@ -283,7 +283,6 @@ class ConvertController extends Controller
*
* @return RedirectResponse|Redirector
*
- * @throws FireflyException
*/
public function postIndex(Request $request, TransactionType $destinationType, TransactionGroup $group)
{
diff --git a/app/Http/Controllers/Transaction/DeleteController.php b/app/Http/Controllers/Transaction/DeleteController.php
index aae5daabf5..1ee1b81a90 100644
--- a/app/Http/Controllers/Transaction/DeleteController.php
+++ b/app/Http/Controllers/Transaction/DeleteController.php
@@ -66,7 +66,7 @@ class DeleteController extends Controller
*
* @param TransactionGroup $group
*
- * @return mixed
+ * @return \Illuminate\Contracts\View\Factory|\Illuminate\Contracts\View\View|Redirector|RedirectResponse
*/
public function delete(TransactionGroup $group)
{
diff --git a/app/Http/Controllers/Transaction/MassController.php b/app/Http/Controllers/Transaction/MassController.php
index 7a2ade3c32..666e4f6d83 100644
--- a/app/Http/Controllers/Transaction/MassController.php
+++ b/app/Http/Controllers/Transaction/MassController.php
@@ -91,7 +91,7 @@ class MassController extends Controller
*
* @param MassDeleteJournalRequest $request
*
- * @return mixed
+ * @return \Illuminate\Contracts\Foundation\Application|Redirector|RedirectResponse
*
*/
public function destroy(MassDeleteJournalRequest $request)
diff --git a/app/Http/Controllers/Transaction/ShowController.php b/app/Http/Controllers/Transaction/ShowController.php
index e6deb0e5c7..35250933fb 100644
--- a/app/Http/Controllers/Transaction/ShowController.php
+++ b/app/Http/Controllers/Transaction/ShowController.php
@@ -73,6 +73,7 @@ class ShowController extends Controller
}
/**
+ * @param Request $request
* @param TransactionGroup $transactionGroup
*
* @return Factory|View
diff --git a/app/Http/Middleware/InstallationId.php b/app/Http/Middleware/InstallationId.php
index 0b70627f28..10985827d6 100644
--- a/app/Http/Middleware/InstallationId.php
+++ b/app/Http/Middleware/InstallationId.php
@@ -44,7 +44,6 @@ class InstallationId
*
* @return mixed
*
- * @throws FireflyException
*
*/
public function handle($request, Closure $next)
diff --git a/app/Models/Preference.php b/app/Models/Preference.php
index defa83e588..83f7801074 100644
--- a/app/Models/Preference.php
+++ b/app/Models/Preference.php
@@ -27,14 +27,15 @@ use FireflyIII\User;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
+use Illuminate\Support\Carbon;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
/**
* FireflyIII\Models\Preference
*
* @property int $id
- * @property \Illuminate\Support\Carbon|null $created_at
- * @property \Illuminate\Support\Carbon|null $updated_at
+ * @property Carbon|null $created_at
+ * @property Carbon|null $updated_at
* @property int $user_id
* @property string $name
* @property int|string|array|null $data
diff --git a/app/Services/Internal/Destroy/AccountDestroyService.php b/app/Services/Internal/Destroy/AccountDestroyService.php
index 743fe59bc9..cc557d541f 100644
--- a/app/Services/Internal/Destroy/AccountDestroyService.php
+++ b/app/Services/Internal/Destroy/AccountDestroyService.php
@@ -33,6 +33,7 @@ use FireflyIII\Models\TransactionJournal;
use FireflyIII\Models\TransactionType;
use Illuminate\Database\Eloquent\Builder;
use Log;
+use stdClass;
/**
* Class AccountDestroyService
@@ -130,7 +131,7 @@ class AccountDestroyService
/** @var JournalDestroyService $service */
$service = app(JournalDestroyService::class);
$user = $account->user;
- /** @var \stdClass $row */
+ /** @var stdClass $row */
foreach ($collection as $row) {
if ((int)$row->the_count > 1) {
$journalId = (int)$row->transaction_journal_id;
diff --git a/app/Services/Internal/Support/AccountServiceTrait.php b/app/Services/Internal/Support/AccountServiceTrait.php
index c2bae2535c..d0217f22ff 100644
--- a/app/Services/Internal/Support/AccountServiceTrait.php
+++ b/app/Services/Internal/Support/AccountServiceTrait.php
@@ -275,7 +275,6 @@ trait AccountServiceTrait
* @param string $currencyCode
*
* @return TransactionCurrency
- * @throws JsonException
*/
protected function getCurrency(int $currencyId, string $currencyCode): TransactionCurrency
{
diff --git a/app/Services/Internal/Support/BillServiceTrait.php b/app/Services/Internal/Support/BillServiceTrait.php
index bf79f2330f..9df0a307dc 100644
--- a/app/Services/Internal/Support/BillServiceTrait.php
+++ b/app/Services/Internal/Support/BillServiceTrait.php
@@ -49,7 +49,6 @@ trait BillServiceTrait
return;
}
$ruleIds = $bill->user->rules()->get(['id'])->pluck('id')->toArray();
- /** @var Collection $set */
$set = RuleAction::whereIn('rule_id', $ruleIds)
->where('action_type', 'link_to_bill')
->where('action_value', $oldName)->get();
diff --git a/app/Services/Internal/Support/JournalServiceTrait.php b/app/Services/Internal/Support/JournalServiceTrait.php
index 4427665776..4186cb3028 100644
--- a/app/Services/Internal/Support/JournalServiceTrait.php
+++ b/app/Services/Internal/Support/JournalServiceTrait.php
@@ -194,7 +194,7 @@ trait JournalServiceTrait
* @param array $data
* @param string $preferredType
*
- * @return Account
+ * @return Account|null
* @throws FireflyException
*/
private function createAccount(?Account $account, array $data, string $preferredType): ?Account
@@ -302,7 +302,7 @@ trait JournalServiceTrait
/**
* @param string|null $amount
*
- * @return string
+ * @return string|null
* @codeCoverageIgnore
*/
protected function getForeignAmount(?string $amount): ?string
@@ -372,7 +372,7 @@ trait JournalServiceTrait
/**
* @param TransactionJournal $journal
- * @param string $notes
+ * @param string|null $notes
*
* @codeCoverageIgnore
*/
@@ -405,7 +405,7 @@ trait JournalServiceTrait
* Link tags to journal.
*
* @param TransactionJournal $journal
- * @param array $tags
+ * @param array|null $tags
*
* @codeCoverageIgnore
*/
diff --git a/app/Services/Internal/Support/RecurringTransactionTrait.php b/app/Services/Internal/Support/RecurringTransactionTrait.php
index 205931e2a1..ffd5a6773f 100644
--- a/app/Services/Internal/Support/RecurringTransactionTrait.php
+++ b/app/Services/Internal/Support/RecurringTransactionTrait.php
@@ -257,6 +257,8 @@ trait RecurringTransactionTrait
/**
* @param RecurrenceTransaction $transaction
* @param int $categoryId
+ *
+ * @throws FireflyException
*/
private function setCategory(RecurrenceTransaction $transaction, int $categoryId): void
{
diff --git a/app/Services/Internal/Update/AccountUpdateService.php b/app/Services/Internal/Update/AccountUpdateService.php
index e84f5038a9..7943fa7f14 100644
--- a/app/Services/Internal/Update/AccountUpdateService.php
+++ b/app/Services/Internal/Update/AccountUpdateService.php
@@ -77,6 +77,8 @@ class AccountUpdateService
* @param array $data
*
* @return Account
+ * @throws FireflyException
+ * @throws \JsonException
*/
public function update(Account $account, array $data): Account
{
@@ -179,6 +181,8 @@ class AccountUpdateService
/**
* @param string $type
+ *
+ * @return AccountType
*/
private function getAccountType(string $type): AccountType
{
@@ -219,7 +223,7 @@ class AccountUpdateService
$this->user->accounts()->where('accounts.order', '<=', $newOrder)->where('accounts.order', '>', $oldOrder)
->where('accounts.id', '!=', $account->id)
->whereIn('accounts.account_type_id', $list)
- ->decrement('order', 1);
+ ->decrement('order');
$account->order = $newOrder;
Log::debug(sprintf('Order of account #%d ("%s") is now %d', $account->id, $account->name, $newOrder));
$account->save();
@@ -230,7 +234,7 @@ class AccountUpdateService
$this->user->accounts()->where('accounts.order', '>=', $newOrder)->where('accounts.order', '<', $oldOrder)
->where('accounts.id', '!=', $account->id)
->whereIn('accounts.account_type_id', $list)
- ->increment('order', 1);
+ ->increment('order');
$account->order = $newOrder;
Log::debug(sprintf('Order of account #%d ("%s") is now %d', $account->id, $account->name, $newOrder));
$account->save();
@@ -339,6 +343,8 @@ class AccountUpdateService
/**
* @param Account $account
+ *
+ * @throws FireflyException
*/
private function updatePreferences(Account $account): void
{
diff --git a/app/Services/Internal/Update/BillUpdateService.php b/app/Services/Internal/Update/BillUpdateService.php
index c1a1cc1ffb..49430f51be 100644
--- a/app/Services/Internal/Update/BillUpdateService.php
+++ b/app/Services/Internal/Update/BillUpdateService.php
@@ -184,14 +184,14 @@ class BillUpdateService
if ($newOrder > $oldOrder) {
$this->user->bills()->where('order', '<=', $newOrder)->where('order', '>', $oldOrder)
->where('bills.id', '!=', $bill->id)
- ->decrement('bills.order', 1);
+ ->decrement('bills.order');
$bill->order = $newOrder;
$bill->save();
}
if ($newOrder < $oldOrder) {
$this->user->bills()->where('order', '>=', $newOrder)->where('order', '<', $oldOrder)
->where('bills.id', '!=', $bill->id)
- ->increment('bills.order', 1);
+ ->increment('bills.order');
$bill->order = $newOrder;
$bill->save();
}
diff --git a/app/Services/Internal/Update/CategoryUpdateService.php b/app/Services/Internal/Update/CategoryUpdateService.php
index 1db4e1c845..dd975d48d1 100644
--- a/app/Services/Internal/Update/CategoryUpdateService.php
+++ b/app/Services/Internal/Update/CategoryUpdateService.php
@@ -62,6 +62,7 @@ class CategoryUpdateService
* @param array $data
*
* @return Category
+ * @throws Exception
*/
public function update(Category $category, array $data): Category
{
diff --git a/app/Services/Internal/Update/GroupUpdateService.php b/app/Services/Internal/Update/GroupUpdateService.php
index 3146eea33b..a987c818b9 100644
--- a/app/Services/Internal/Update/GroupUpdateService.php
+++ b/app/Services/Internal/Update/GroupUpdateService.php
@@ -165,6 +165,7 @@ class GroupUpdateService
* @param array $data
*
* @throws FireflyException
+ * @throws \FireflyIII\Exceptions\DuplicateTransactionException
*/
private function createTransactionJournal(TransactionGroup $transactionGroup, array $data): void
{
diff --git a/app/Services/Internal/Update/RecurrenceUpdateService.php b/app/Services/Internal/Update/RecurrenceUpdateService.php
index 7570e9f9b3..77c2a48ff7 100644
--- a/app/Services/Internal/Update/RecurrenceUpdateService.php
+++ b/app/Services/Internal/Update/RecurrenceUpdateService.php
@@ -143,6 +143,8 @@ class RecurrenceUpdateService
*
* @param Recurrence $recurrence
* @param array $repetitions
+ *
+ * @throws FireflyException
*/
private function updateRepetitions(Recurrence $recurrence, array $repetitions): void
{
@@ -184,7 +186,8 @@ class RecurrenceUpdateService
}
/**
- * @param array $data
+ * @param Recurrence $recurrence
+ * @param array $data
*
* @return RecurrenceRepetition|null
*/
@@ -308,7 +311,8 @@ class RecurrenceUpdateService
}
/**
- * @param array $data
+ * @param Recurrence $recurrence
+ * @param array $data
*
* @return RecurrenceTransaction|null
*/
diff --git a/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php b/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php
index 0c5b82647d..58530fec37 100644
--- a/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php
+++ b/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php
@@ -193,7 +193,7 @@ trait CalculateRangeOccurrences
if (0 === $attempts % $skipMod) {
$return[] = clone $obj;
}
- $obj->addYears(1);
+ $obj->addYears();
$count++;
$attempts++;
}
diff --git a/app/Support/Repositories/Recurring/CalculateXOccurrences.php b/app/Support/Repositories/Recurring/CalculateXOccurrences.php
index 17e4ed252a..18265fcf02 100644
--- a/app/Support/Repositories/Recurring/CalculateXOccurrences.php
+++ b/app/Support/Repositories/Recurring/CalculateXOccurrences.php
@@ -200,7 +200,7 @@ trait CalculateXOccurrences
$return[] = clone $obj;
$total++;
}
- $obj->addYears(1);
+ $obj->addYears();
$attempts++;
}