Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
No errors on level 1.
James Coled95f3ca59fa9
diff --git a/.ci/phpstan.neon b/.ci/phpstan.neonindex 3f5e7f060e..3dfe2330a9 100644--- a/.ci/phpstan.neon+++ b/.ci/phpstan.neon@@ -5,49 +5,49 @@ parameters:reportUnmatchedIgnoredErrors: falseignoreErrors:# TODO: slowly remove these exceptions and fix the issues found.- - '#Dynamic call to static method#' # all the Laravel ORM things depend on this.- - '#Control structures using switch should not be used.#' # switch is fine in some cases.- - '#with no value type specified in iterable type array#' # remove this rule when all other issues are solved.- - '#has no value type specified in iterable type array#' # remove this rule when all other issues are solved.- - '#is not allowed to extend#'- - '#does not specify its types#'- - '#switch is forbidden to use#'- - '#is neither abstract nor final#'- - '#on left side of \?\?\= always exists and is not nullable#'- - '#has a nullable return type declaration#' # perhaps throw errors instead?- - '#with a nullable type declaration#' # decide what action should be if param is null.- - '#with null as default value#'- -- message: '#Constructor in [a-zA-Z0-9\\_]+ has parameter \$[a-zA-Z0-9\\_]+ with default value#'- paths:- - ../app/Exceptions/IntervalException.php- - ../app/Support/Navigation.php- -- message: '#but containers should not be injected#'- paths:- - ../app/Support/Authentication/RemoteUserGuard.php- -- message: '#Function compact\(\) should not be used#' # too useful in template rendering.- paths:- - ../app/Generator/Report/Account/MonthReportGenerator.php- - ../app/Generator/Report/Audit/MonthReportGenerator.php- - ../app/Generator/Report/Budget/MonthReportGenerator.php- - ../app/Generator/Report/Category/MonthReportGenerator.php- - ../app/Generator/Report/Standard/MonthReportGenerator.php- - ../app/Generator/Report/Standard/MultiYearReportGenerator.php- - ../app/Generator/Report/Standard/YearReportGenerator.php- - ../app/Generator/Report/Tag/MonthReportGenerator.php- - ../app/Http/Controllers/Account/*.php- - ../app/Http/Controllers/Admin/*.php- - ../app/Http/Controllers/*.php- - ../app/Support/ExpandedForm.php- - ../app/Support/Form/AccountForm.php- - ../app/Support/Form/CurrencyForm.php- - ../app/Support/Form/FormSupport.php- -- message: '#Either catch a more specific exception#'- paths:- - ../app/Support/Form/FormSupport.php+ # - '#Dynamic call to static method#' # all the Laravel ORM things depend on this.+ # - '#Control structures using switch should not be used.#' # switch is fine in some cases.+ # - '#with no value type specified in iterable type array#' # remove this rule when all other issues are solved.+ # - '#has no value type specified in iterable type array#' # remove this rule when all other issues are solved.+ # - '#is not allowed to extend#'+ # - '#does not specify its types#'+ # - '#switch is forbidden to use#'+ # - '#is neither abstract nor final#'+ # - '#on left side of \?\?\= always exists and is not nullable#'+ # - '#has a nullable return type declaration#' # perhaps throw errors instead?+ # - '#with a nullable type declaration#' # decide what action should be if param is null.+ # - '#with null as default value#'+ # -+ # message: '#Constructor in [a-zA-Z0-9\\_]+ has parameter \$[a-zA-Z0-9\\_]+ with default value#'+ # paths:+ # - ../app/Exceptions/IntervalException.php+ # - ../app/Support/Navigation.php+ # -+ # message: '#but containers should not be injected#'+ # paths:+ # - ../app/Support/Authentication/RemoteUserGuard.php+ # -+ # message: '#Function compact\(\) should not be used#' # too useful in template rendering.+ # paths:+ # - ../app/Generator/Report/Account/MonthReportGenerator.php+ # - ../app/Generator/Report/Audit/MonthReportGenerator.php+ # - ../app/Generator/Report/Budget/MonthReportGenerator.php+ # - ../app/Generator/Report/Category/MonthReportGenerator.php+ # - ../app/Generator/Report/Standard/MonthReportGenerator.php+ # - ../app/Generator/Report/Standard/MultiYearReportGenerator.php+ # - ../app/Generator/Report/Standard/YearReportGenerator.php+ # - ../app/Generator/Report/Tag/MonthReportGenerator.php+ # - ../app/Http/Controllers/Account/*.php+ # - ../app/Http/Controllers/Admin/*.php+ # - ../app/Http/Controllers/*.php+ # - ../app/Support/ExpandedForm.php+ # - ../app/Support/Form/AccountForm.php+ # - ../app/Support/Form/CurrencyForm.php+ # - ../app/Support/Form/FormSupport.php+ # -+ # message: '#Either catch a more specific exception#'+ # paths:+ # - ../app/Support/Form/FormSupport.phppaths:- ../app- ../databasediff --git a/app/Console/Commands/Correction/ConvertsDatesToUTC.php b/app/Console/Commands/Correction/ConvertsDatesToUTC.phpindex 54ff325777..b9d03027b1 100644--- a/app/Console/Commands/Correction/ConvertsDatesToUTC.php+++ b/app/Console/Commands/Correction/ConvertsDatesToUTC.php@@ -122,7 +122,7 @@ class ConvertsDatesToUTC extends Command$items->each(function ($item) use ($field, $timezoneField): void {/** @var Carbon $date */- $date = Carbon::parse($item->{$field}, $item->{$timezoneField});+ $date = Carbon::parse($item->{$field}, $item->{$timezoneField}); // @phpstan-ignore-line$date->setTimezone('UTC');$item->{$field} = $date->format('Y-m-d H:i:s'); // @phpstan-ignore-line$item->{$timezoneField} = 'UTC'; // @phpstan-ignore-linediff --git a/app/Console/Commands/System/CreatesDatabase.php b/app/Console/Commands/System/CreatesDatabase.phpindex f4c228eb68..c102c091e9 100644--- a/app/Console/Commands/System/CreatesDatabase.php+++ b/app/Console/Commands/System/CreatesDatabase.php@@ -52,7 +52,7 @@ class CreatesDatabase extends Command$exists = false;$dsn = sprintf('mysql:host=%s;port=%d;charset=utf8mb4', config('database.mysql.host'), config('database.mysql.port'));- if ('' !== env('DB_SOCKET', '')) {+ if ('' !== config('database.mysql.unix_socket')) {$dsn = sprintf('mysql:unix_socket=%s;charset=utf8mb4', config('database.mysql.unix_socket'));}$this->friendlyLine(sprintf('DSN is %s', $dsn));