fix phpstan issues.

This commit is contained in:
James Cole
2023-11-28 17:18:31 +01:00
parent 7cb919e9c2
commit b0a39c00ba
25 changed files with 184 additions and 180 deletions

View File

@@ -7,14 +7,14 @@ parameters:
ignoreErrors:
# 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 insome cases.
- '#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#'
- '#switch is forbidden to use#'
- '#is neither abstract nor final#'
- '#has a nullable return type declaration#'
- '#with a nullable type declaration#'
- '#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#'
@@ -56,5 +56,5 @@ parameters:
# The level 8 is the highest level. original was 5
# TODO: slowly up the level and fix the issues found.
level: 6
level: 7