diff --git a/phpstan.neon.dist b/phpstan.neon.dist index a90567227621..2f4b0736aee3 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -30,12 +30,10 @@ parameters: - '#Access to an undefined property CodeIgniter\\Database\\Forge::\$dropConstraintStr#' - '#Access to an undefined property CodeIgniter\\Database\\BaseConnection::\$mysqli|\$schema#' - '#Access to an undefined property CodeIgniter\\Database\\ConnectionInterface::(\$DBDriver|\$connID|\$likeEscapeStr|\$likeEscapeChar|\$escapeChar|\$protectIdentifiers|\$schema)#' - - '#Access to an undefined property CodeIgniter\\HTTP\\Request::\$uri#' - '#Access to protected property CodeIgniter\\Database\\BaseConnection::(\$DBDebug|\$DBPrefix|\$swapPre|\$charset|\$DBCollat|\$database)#' - '#Call to an undefined method CodeIgniter\\Database\\BaseConnection::_(disable|enable)ForeignKeyChecks\(\)#' - '#Call to an undefined method CodeIgniter\\Database\\BaseConnection::supportsForeignKeys\(\)#' - '#Call to an undefined method CodeIgniter\\Database\\ConnectionInterface::(tableExists|protectIdentifiers|setAliasedTables|escapeIdentifiers|affectedRows|addTableAlias|getIndexData)\(\)#' - - '#Call to an undefined method CodeIgniter\\HTTP\\Request::(getPath|getSegments|getMethod|setLocale|getPost)\(\)#' - '#Call to an undefined method CodeIgniter\\Router\\RouteCollectionInterface::(getDefaultNamespace|isFiltered|getFilterForRoute|getRoutesOptions)\(\)#' - '#Cannot access property [\$a-z_]+ on ((bool\|)?object\|resource)#' - '#Cannot call method [a-zA-Z_]+\(\) on ((bool\|)?object\|resource)#' diff --git a/system/CodeIgniter.php b/system/CodeIgniter.php index 9125887f2049..ea3111c8673e 100644 --- a/system/CodeIgniter.php +++ b/system/CodeIgniter.php @@ -77,7 +77,7 @@ class CodeIgniter /** * Current request. * - * @var HTTP\Request|HTTP\IncomingRequest|CLIRequest|RequestInterface + * @var HTTP\Request|HTTP\IncomingRequest|CLIRequest */ protected $request; @@ -581,7 +581,6 @@ protected function getRequestObject() return; } - // @phpstan-ignore-next-line if (is_cli() && ENVIRONMENT !== 'testing') { // @codeCoverageIgnoreStart @@ -842,7 +841,6 @@ protected function determinePath() return $this->path; } - // @phpstan-ignore-next-line return (is_cli() && ! (ENVIRONMENT === 'testing')) ? $this->request->getPath() : $this->request->uri->getPath(); }