File tree Expand file tree Collapse file tree
wcfsetup/install/files/lib/action Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -45,8 +45,17 @@ public function handle(ServerRequestInterface $request): ResponseInterface
4545 throw new UserInputException ('gridView ' , 'invalid ' );
4646 }
4747
48- /** @var AbstractGridView<DatabaseObject, DatabaseObjectList<DatabaseObject>> $view */
49- $ view = new $ parameters ['gridView ' ](...$ parameters ['gridViewParameters ' ]);
48+ try {
49+ /** @var AbstractGridView<DatabaseObject, DatabaseObjectList<DatabaseObject>> $view */
50+ $ view = new $ parameters ['gridView ' ](...$ parameters ['gridViewParameters ' ]);
51+ // @phpstan-ignore catch.neverThrown
52+ } catch (\ArgumentCountError $ e ) {
53+ if (\ENABLE_DEBUG_MODE ) {
54+ throw $ e ;
55+ } else {
56+ throw new IllegalLinkException ();
57+ }
58+ }
5059
5160 if (!$ view ->isAccessible ()) {
5261 throw new PermissionDeniedException ();
Original file line number Diff line number Diff line change @@ -48,6 +48,7 @@ public function handle(ServerRequestInterface $request): ResponseInterface
4848 try {
4949 /** @var AbstractListView<DatabaseObject, DatabaseObjectList<DatabaseObject>> $view */
5050 $ view = new $ parameters ['listView ' ](...$ parameters ['listViewParameters ' ]);
51+ // @phpstan-ignore catch.neverThrown
5152 } catch (\ArgumentCountError $ e ) {
5253 if (\ENABLE_DEBUG_MODE ) {
5354 throw $ e ;
You can’t perform that action at this time.
0 commit comments