diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index 4e2d11b71e..f6fd2a87e0 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -460,11 +460,6 @@ parameters: count: 1 path: libraries/classes/Controllers/Preferences/ManageController.php - - - message: "#^Property PhpMyAdmin\\\\Controllers\\\\Server\\\\BinlogController\\:\\:\\$binaryLogs has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Controllers/Server/BinlogController.php - - message: "#^Argument of an invalid type array\\|null supplied for foreach, only iterables are supported\\.$#" count: 1 @@ -1370,11 +1365,6 @@ parameters: count: 1 path: libraries/classes/Engines/Pbxt.php - - - message: "#^Property PhpMyAdmin\\\\Error\\:\\:\\$hide_location has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Error.php - - message: "#^Elseif branch is unreachable because previous condition is always true\\.$#" count: 1 @@ -1390,16 +1380,6 @@ parameters: count: 1 path: libraries/classes/Error.php - - - message: "#^Property PhpMyAdmin\\\\ErrorHandler\\:\\:\\$hide_location has no typehint specified\\.$#" - count: 1 - path: libraries/classes/ErrorHandler.php - - - - message: "#^Property PhpMyAdmin\\\\ErrorHandler\\:\\:\\$error_reporting has no typehint specified\\.$#" - count: 1 - path: libraries/classes/ErrorHandler.php - - message: "#^Parameter \\#1 \\$error_handler of function set_error_handler expects \\(callable\\(int, string, string, int, array\\)\\: bool\\)\\|null, array\\(\\$this\\(PhpMyAdmin\\\\ErrorHandler\\), 'handleError'\\) given\\.$#" count: 1 @@ -3910,16 +3890,6 @@ parameters: count: 1 path: libraries/classes/Server/Status/Monitor.php - - - message: "#^Property PhpMyAdmin\\\\Server\\\\SysInfo\\\\Base\\:\\:\\$os has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Server/SysInfo/Base.php - - - - message: "#^Property PhpMyAdmin\\\\Server\\\\SysInfo\\\\Linux\\:\\:\\$os has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Server/SysInfo/Linux.php - - message: "#^Cannot access offset 1 on array\\\\|false\\.$#" count: 1 @@ -3940,26 +3910,16 @@ parameters: count: 1 path: libraries/classes/Server/SysInfo/Linux.php - - - message: "#^Property PhpMyAdmin\\\\Server\\\\SysInfo\\\\SunOs\\:\\:\\$os has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Server/SysInfo/SunOs.php - - - - message: "#^Property PhpMyAdmin\\\\Server\\\\SysInfo\\\\WindowsNt\\:\\:\\$_wmi has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Server/SysInfo/WindowsNt.php - - - - message: "#^Property PhpMyAdmin\\\\Server\\\\SysInfo\\\\WindowsNt\\:\\:\\$os has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Server/SysInfo/WindowsNt.php - - message: "#^Call to an undefined method COM\\:\\:ConnectServer\\(\\)\\.$#" count: 1 path: libraries/classes/Server/SysInfo/WindowsNt.php + - + message: "#^Cannot call method Get\\(\\) on COM\\|null\\.$#" + count: 1 + path: libraries/classes/Server/SysInfo/WindowsNt.php + - message: "#^Parameter \\#1 \\$string of function htmlspecialchars expects string, int\\|string given\\.$#" count: 1 @@ -4305,16 +4265,6 @@ parameters: count: 1 path: libraries/classes/ThemeManager.php - - - message: "#^Property PhpMyAdmin\\\\Tracker\\:\\:\\$enabled has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Tracker.php - - - - message: "#^Property PhpMyAdmin\\\\Tracker\\:\\:\\$_tracking_cache has no typehint specified\\.$#" - count: 1 - path: libraries/classes/Tracker.php - - message: "#^Parameter \\#3 \\$version of static method PhpMyAdmin\\\\Tracker\\:\\:deactivateTracking\\(\\) expects string, int given\\.$#" count: 1 @@ -5320,11 +5270,6 @@ parameters: count: 1 path: test/classes/UtilTest.php - - - message: "#^Property PhpMyAdmin\\\\Tests\\\\VersionInformationTest\\:\\:\\$_releases has no typehint specified\\.$#" - count: 1 - path: test/classes/VersionInformationTest.php - - message: "#^Cannot access property \\$version on stdClass\\|null\\.$#" count: 1 diff --git a/psalm-baseline.xml b/psalm-baseline.xml index e0bca3a5bf..0c8e6752cf 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -511,11 +511,6 @@ $extra_data - - - $selected - - $this->dbi->fetchSingleRow($sql_query) @@ -2422,6 +2417,15 @@ shell_exec('kstat -p d ' . $key) + + + Get + + + COM|null + $this->_wmi + + $result