From 71dea2712cd26b734a7b2faa2354cb550aea5cbb Mon Sep 17 00:00:00 2001 From: Greg Roach Date: Thu, 4 Mar 2021 09:19:40 +0000 Subject: Fix: #3622 - cannot create family from family selector --- phpstan-baseline.neon | 149 +++++++++++++++++++++++++++++--------------------- 1 file changed, 87 insertions(+), 62 deletions(-) (limited to 'phpstan-baseline.neon') diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index edc3f7522e..f93a1c0e79 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -101,7 +101,7 @@ parameters: path: app/Functions/FunctionsImport.php - - message: "#^Parameter \\#2 \\$start of function substr expects int, int\\<0, max\\>\\|false given\\.$#" + message: "#^Parameter \\#2 \\$offset of function substr expects int, int\\<0, max\\>\\|false given\\.$#" count: 1 path: app/Functions/FunctionsPrint.php @@ -111,12 +111,12 @@ parameters: path: app/Functions/FunctionsPrint.php - - message: "#^Parameter \\#2 \\.\\.\\.\\$args of function array_merge expects array, array\\\\|false given\\.$#" + message: "#^Parameter \\#2 \\.\\.\\.\\$arrays of function array_merge expects array, array\\\\|false given\\.$#" count: 1 path: app/Functions/FunctionsPrint.php - - message: "#^Parameter \\#1 \\$arr1 of function array_intersect expects array, array\\\\|false given\\.$#" + message: "#^Parameter \\#1 \\$array of function array_intersect expects array, array\\\\|false given\\.$#" count: 1 path: app/Functions/FunctionsPrint.php @@ -131,7 +131,7 @@ parameters: path: app/Functions/FunctionsPrintFacts.php - - message: "#^Parameter \\#2 \\$start of function substr expects int, int\\<0, max\\>\\|false given\\.$#" + message: "#^Parameter \\#2 \\$offset of function substr expects int, int\\<0, max\\>\\|false given\\.$#" count: 1 path: app/Functions/FunctionsPrintFacts.php @@ -180,12 +180,12 @@ parameters: path: app/Functions/FunctionsRtl.php - - message: "#^Parameter \\#3 \\$length of function substr expects int, int\\<0, max\\>\\|false given\\.$#" + message: "#^Parameter \\#3 \\$length of function substr expects int\\|null, int\\<0, max\\>\\|false given\\.$#" count: 2 path: app/Functions/FunctionsRtl.php - - message: "#^Parameter \\#2 \\$start of function substr expects int, int\\<0, max\\>\\|false given\\.$#" + message: "#^Parameter \\#2 \\$offset of function substr expects int, int\\<0, max\\>\\|false given\\.$#" count: 2 path: app/Functions/FunctionsRtl.php @@ -200,7 +200,7 @@ parameters: path: app/GedcomRecord.php - - message: "#^Parameter \\#1 \\$str of function trim expects string, string\\|null given\\.$#" + message: "#^Parameter \\#1 \\$string of function trim expects string, string\\|null given\\.$#" count: 3 path: app/GedcomRecord.php @@ -225,7 +225,7 @@ parameters: path: app/GedcomRecord.php - - message: "#^Parameter \\#1 \\$stack of function array_shift expects array, array\\\\|false given\\.$#" + message: "#^Parameter \\#1 \\$array of function array_shift expects array, array\\\\|false given\\.$#" count: 3 path: app/GedcomRecord.php @@ -300,7 +300,7 @@ parameters: path: app/Http/Middleware/UseTransaction.php - - message: "#^Parameter \\#1 \\$function of function call_user_func expects callable\\(\\)\\: mixed, array\\(mixed, string\\) given\\.$#" + message: "#^Parameter \\#1 \\$callback of function call_user_func expects callable\\(\\)\\: mixed, array\\(mixed, string\\) given\\.$#" count: 1 path: app/Http/Middleware/WrapHandler.php @@ -355,12 +355,12 @@ parameters: path: app/Http/RequestHandlers/EditNoteAction.php - - message: "#^Parameter \\#1 \\$str of function trim expects string, string\\|null given\\.$#" + message: "#^Parameter \\#1 \\$string of function trim expects string, string\\|null given\\.$#" count: 1 path: app/Http/RequestHandlers/EditRawRecordAction.php - - message: "#^Parameter \\#1 \\$fp of function stream_get_meta_data expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function stream_get_meta_data expects resource, resource\\|false given\\.$#" count: 1 path: app/Http/RequestHandlers/ExportGedcomClient.php @@ -430,7 +430,7 @@ parameters: path: app/Http/RequestHandlers/ImportGedcomAction.php - - message: "#^Parameter \\#1 \\$str of function sha1 expects string, string\\|false given\\.$#" + message: "#^Parameter \\#1 \\$string of function sha1 expects string, string\\|false given\\.$#" count: 1 path: app/Http/RequestHandlers/ImportThumbnailsAction.php @@ -509,33 +509,13 @@ parameters: count: 1 path: app/Http/RequestHandlers/MapDataImportAction.php - - - message: "#^Offset 0 does not exist on array\\|null\\.$#" - count: 2 - path: app/Http/RequestHandlers/MapDataImportAction.php - - - - message: "#^Parameter \\#1 \\$var of function count expects array\\|Countable, array\\|null given\\.$#" - count: 1 - path: app/Http/RequestHandlers/MapDataImportAction.php - - - - message: "#^Parameter \\#1 \\$input of function array_slice expects array, array\\|null given\\.$#" - count: 1 - path: app/Http/RequestHandlers/MapDataImportAction.php - - - - message: "#^Offset int does not exist on array\\|null\\.$#" - count: 2 - path: app/Http/RequestHandlers/MapDataImportAction.php - - message: "#^Parameter \\#1 \\$gedcom of method Fisharebest\\\\Webtrees\\\\GedcomRecord\\:\\:updateRecord\\(\\) expects string, string\\|null given\\.$#" count: 1 path: app/Http/RequestHandlers/MergeFactsAction.php - - message: "#^Parameter \\#1 \\$function of function call_user_func expects callable\\(\\)\\: mixed, array\\(Fisharebest\\\\Webtrees\\\\Module\\\\ModuleInterface, string\\) given\\.$#" + message: "#^Parameter \\#1 \\$callback of function call_user_func expects callable\\(\\)\\: mixed, array\\(Fisharebest\\\\Webtrees\\\\Module\\\\ModuleInterface, string\\) given\\.$#" count: 1 path: app/Http/RequestHandlers/ModuleAction.php @@ -560,7 +540,7 @@ parameters: path: app/Http/RequestHandlers/SearchGeneralPage.php - - message: "#^Parameter \\#2 \\.\\.\\.\\$args of function array_merge expects array, array\\\\|false given\\.$#" + message: "#^Parameter \\#2 \\.\\.\\.\\$arrays of function array_merge expects array, array\\\\|false given\\.$#" count: 1 path: app/Http/RequestHandlers/SearchReplaceAction.php @@ -599,6 +579,11 @@ parameters: count: 1 path: app/Http/RequestHandlers/SiteLogsData.php + - + message: "#^Cannot cast array\\|string\\|false to int\\.$#" + count: 1 + path: app/Http/RequestHandlers/SitePreferencesPage.php + - message: "#^Parameter \\#2 \\$resource of method League\\\\Flysystem\\\\FilesystemInterface\\:\\:writeStream\\(\\) expects resource, resource\\|null given\\.$#" count: 1 @@ -630,7 +615,7 @@ parameters: path: app/Individual.php - - message: "#^Parameter \\#1 \\$numerator of function intdiv expects int, float\\|int given\\.$#" + message: "#^Parameter \\#1 \\$num1 of function intdiv expects int, float\\|int given\\.$#" count: 1 path: app/Individual.php @@ -705,7 +690,7 @@ parameters: path: app/Module/CensusAssistantModule.php - - message: "#^Parameter \\#1 \\$fp of function stream_get_meta_data expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function stream_get_meta_data expects resource, resource\\|false given\\.$#" count: 1 path: app/Module/ClippingsCartModule.php @@ -725,22 +710,22 @@ parameters: path: app/Module/FamilyTreeNewsModule.php - - message: "#^Parameter \\#1 \\$im of function imagecolorallocate expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagecolorallocate expects GdImage, GdImage\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php - - message: "#^Parameter \\#1 \\$im of function imagecolortransparent expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagecolortransparent expects GdImage, GdImage\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php - - message: "#^Parameter \\#2 \\$col of function imagecolortransparent expects int, int\\|false given\\.$#" + message: "#^Parameter \\#2 \\$color of function imagecolortransparent expects int\\|null, int\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php - - message: "#^Parameter \\#1 \\$image of method Fisharebest\\\\Webtrees\\\\Module\\\\FanChartModule\\:\\:imageColor\\(\\) expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of method Fisharebest\\\\Webtrees\\\\Module\\\\FanChartModule\\:\\:imageColor\\(\\) expects resource, GdImage\\|false given\\.$#" count: 4 path: app/Module/FanChartModule.php @@ -750,12 +735,12 @@ parameters: path: app/Module/FanChartModule.php - - message: "#^Parameter \\#1 \\$im of function imagefilledrectangle expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagefilledrectangle expects GdImage, GdImage\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php - - message: "#^Parameter \\#6 \\$col of function imagefilledrectangle expects int, int\\|false given\\.$#" + message: "#^Parameter \\#6 \\$color of function imagefilledrectangle expects int, int\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php @@ -765,22 +750,22 @@ parameters: path: app/Module/FanChartModule.php - - message: "#^Parameter \\#1 \\$im of function imagefilledarc expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagefilledarc expects GdImage, GdImage\\|false given\\.$#" count: 2 path: app/Module/FanChartModule.php - - message: "#^Parameter \\#1 \\$im of function imagettftext expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagettftext expects GdImage, GdImage\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php - - message: "#^Parameter \\#1 \\$im of function imagepng expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagepng expects GdImage, GdImage\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php - - message: "#^Parameter \\#1 \\$im of function imagedestroy expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagedestroy expects GdImage, GdImage\\|false given\\.$#" count: 1 path: app/Module/FanChartModule.php @@ -789,6 +774,11 @@ parameters: count: 1 path: app/Module/FanChartModule.php + - + message: "#^Parameter \\#1 \\$image of function imagecolorallocate expects GdImage, resource given\\.$#" + count: 1 + path: app/Module/FanChartModule.php + - message: "#^Method Fisharebest\\\\Webtrees\\\\Module\\\\FixDuplicateLinks\\:\\:updateGedcom\\(\\) should return string but returns string\\|null\\.$#" count: 1 @@ -880,7 +870,7 @@ parameters: path: app/Module/IndividualListModule.php - - message: "#^Parameter \\#1 \\$str of function strip_tags expects string, string\\|false given\\.$#" + message: "#^Parameter \\#1 \\$string of function strip_tags expects string, string\\|false given\\.$#" count: 1 path: app/Module/IndividualMetadataModule.php @@ -1335,7 +1325,17 @@ parameters: path: app/Report/ReportHtmlTextbox.php - - message: "#^Parameter \\#1 \\$function of function call_user_func expects callable\\(\\)\\: mixed, array\\(\\$this\\(Fisharebest\\\\Webtrees\\\\Report\\\\ReportParserBase\\), string\\) given\\.$#" + message: "#^Property Fisharebest\\\\Webtrees\\\\Report\\\\ReportParserBase\\:\\:\\$xml_parser \\(resource\\) does not accept XMLParser\\.$#" + count: 1 + path: app/Report/ReportParserBase.php + + - + message: "#^Parameter \\#3 \\$value of function xml_parser_set_option expects int\\|string, false given\\.$#" + count: 1 + path: app/Report/ReportParserBase.php + + - + message: "#^Parameter \\#1 \\$callback of function call_user_func expects callable\\(\\)\\: mixed, array\\(\\$this\\(Fisharebest\\\\Webtrees\\\\Report\\\\ReportParserBase\\), string\\) given\\.$#" count: 2 path: app/Report/ReportParserBase.php @@ -1345,7 +1345,7 @@ parameters: path: app/Report/ReportParserGenerate.php - - message: "#^Parameter \\#1 \\$function of function call_user_func expects callable\\(\\)\\: mixed, array\\(\\$this\\(Fisharebest\\\\Webtrees\\\\Report\\\\ReportParserGenerate\\), string\\) given\\.$#" + message: "#^Parameter \\#1 \\$callback of function call_user_func expects callable\\(\\)\\: mixed, array\\(\\$this\\(Fisharebest\\\\Webtrees\\\\Report\\\\ReportParserGenerate\\), string\\) given\\.$#" count: 2 path: app/Report/ReportParserGenerate.php @@ -1395,22 +1395,37 @@ parameters: path: app/Report/ReportParserGenerate.php - - message: "#^Parameter \\#1 \\$array_arg of function end expects array\\|object, array\\\\|false given\\.$#" + message: "#^Parameter \\#1 \\$array of function end expects array, array\\\\|false given\\.$#" count: 1 path: app/Report/ReportParserGenerate.php + - + message: "#^Parameter \\#1 \\$parser of function xml_get_current_line_number expects XMLParser, resource given\\.$#" + count: 6 + path: app/Report/ReportParserGenerate.php + - message: "#^Cannot access offset float\\|int on array\\\\|false\\.$#" count: 14 path: app/Report/ReportParserGenerate.php + - + message: "#^Property Fisharebest\\\\Webtrees\\\\Report\\\\ReportParserGenerate\\:\\:\\$parser \\(resource\\) does not accept XMLParser\\.$#" + count: 4 + path: app/Report/ReportParserGenerate.php + + - + message: "#^Parameter \\#3 \\$value of function xml_parser_set_option expects int\\|string, false given\\.$#" + count: 4 + path: app/Report/ReportParserGenerate.php + - message: "#^Cannot call method facts\\(\\) on Fisharebest\\\\Webtrees\\\\GedcomRecord\\|null\\.$#" count: 2 path: app/Report/ReportParserGenerate.php - - message: "#^Parameter \\#1 \\$str of function addslashes expects string, string\\|null given\\.$#" + message: "#^Parameter \\#1 \\$string of function addslashes expects string, string\\|null given\\.$#" count: 1 path: app/Report/ReportParserGenerate.php @@ -1420,12 +1435,12 @@ parameters: path: app/Report/ReportParserGenerate.php - - message: "#^Parameter \\#1 \\$im of function imagesx expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagesx expects GdImage, GdImage\\|false given\\.$#" count: 2 path: app/Report/ReportParserGenerate.php - - message: "#^Parameter \\#1 \\$im of function imagesy expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$image of function imagesy expects GdImage, GdImage\\|false given\\.$#" count: 2 path: app/Report/ReportParserGenerate.php @@ -1590,12 +1605,12 @@ parameters: path: app/Services/AdminService.php - - message: "#^Parameter \\#1 \\$fp of function fread expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function fread expects resource, resource\\|false given\\.$#" count: 1 path: app/Services/AdminService.php - - message: "#^Parameter \\#1 \\$fp of function fclose expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function fclose expects resource, resource\\|false given\\.$#" count: 1 path: app/Services/AdminService.php @@ -1710,7 +1725,7 @@ parameters: path: app/Services/MediaFileService.php - - message: "#^Parameter \\#1 \\$str of function trim expects string, string\\|null given\\.$#" + message: "#^Parameter \\#1 \\$string of function trim expects string, string\\|null given\\.$#" count: 2 path: app/Services/MediaFileService.php @@ -1750,10 +1765,20 @@ parameters: path: app/Services/SearchService.php - - message: "#^Parameter \\#2 \\$str of function explode expects string, string\\|false given\\.$#" + message: "#^Parameter \\#2 \\$string of function explode expects string, string\\|false given\\.$#" count: 2 path: app/Services/ServerCheckService.php + - + message: "#^Comparison operation \"\\<\\=\" between 1 and 0 is always false\\.$#" + count: 1 + path: app/Services/ServerCheckService.php + + - + message: "#^Result of && is always false\\.$#" + count: 1 + path: app/Services/ServerCheckService.php + - message: "#^Parameter \\#1 \\$value of function e expects Illuminate\\\\Contracts\\\\Support\\\\Htmlable\\|string, string\\|false given\\.$#" count: 1 @@ -1765,7 +1790,7 @@ parameters: path: app/Services/SiteLogsService.php - - message: "#^Parameter \\#1 \\$fp of function fwrite expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function fwrite expects resource, resource\\|false given\\.$#" count: 1 path: app/Services/UpgradeService.php @@ -1775,12 +1800,12 @@ parameters: path: app/Services/UpgradeService.php - - message: "#^Parameter \\#1 \\$fp of function ftell expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function ftell expects resource, resource\\|false given\\.$#" count: 1 path: app/Services/UpgradeService.php - - message: "#^Parameter \\#1 \\$fp of function rewind expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function rewind expects resource, resource\\|false given\\.$#" count: 1 path: app/Services/UpgradeService.php @@ -1790,7 +1815,7 @@ parameters: path: app/Services/UpgradeService.php - - message: "#^Parameter \\#1 \\$fp of function fclose expects resource, resource\\|false given\\.$#" + message: "#^Parameter \\#1 \\$stream of function fclose expects resource, resource\\|false given\\.$#" count: 1 path: app/Services/UpgradeService.php @@ -1820,7 +1845,7 @@ parameters: path: app/Statistics.php - - message: "#^Parameter \\#1 \\$function of function call_user_func expects callable\\(\\)\\: mixed, array\\(\\$this\\(Fisharebest\\\\Webtrees\\\\Statistics\\), string\\) given\\.$#" + message: "#^Parameter \\#1 \\$callback of function call_user_func expects callable\\(\\)\\: mixed, array\\(\\$this\\(Fisharebest\\\\Webtrees\\\\Statistics\\), string\\) given\\.$#" count: 2 path: app/Statistics.php -- cgit v1.3