ChurchCRM / CRM

ChurchCRM is an OpenSource Church CRM & Management Software.
https://ChurchCRM.io
MIT License
621 stars 441 forks source link

Bug: Call to undefined method ChurchCRM\...\LocalUsernamePasswordRequest::getQueryParams() #7050

Closed OluwaninsolaAO closed 4 months ago

OluwaninsolaAO commented 4 months ago

Description The first login attempt on a fresh install failed with the error message Call to undefined method ChurchCRM\Authentication\Requests\LocalUsernamePasswordRequest::getQueryParams().

Steps To Reproduce

Steps to reproduce the behavior:

  1. Creates a fresh new install of Church CRM
  2. Try login in with the default username and password

šŸ“‹ Logs:

#0 /home/.../vendor/slim/slim/Slim/Handlers/Strategies/RequestResponse.php(38): beginSession()
#1 /home/.../vendor/slim/slim/Slim/Routing/Route.php(358): Slim\Handlers\Strategies\RequestResponse->__invoke()
#2 /home/.../vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\Routing\Route->handle()
#3 /home/.../vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\MiddlewareDispatcher->handle()
#4 /home/.../vendor/slim/slim/Slim/Routing/Route.php(315): Slim\MiddlewareDispatcher->handle()
#5 /home/.../vendor/slim/slim/Slim/Routing/RouteRunner.php(68): Slim\Routing\Route->run()
#6 /home/.../vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php(76): Slim\Routing\RouteRunner->handle()
#7 /home/.../vendor/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Middleware\ErrorMiddleware->process()
#8 /home/.../vendor/slim/slim/Slim/Middleware/RoutingMiddleware.php(45): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#9 /home/.../vendor/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Middleware\RoutingMiddleware->process()
#10 /home/.../ChurchCRM/Slim/Middleware/VersionMiddleware.php(14): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#11 /home/.../vendor/slim/slim/Slim/MiddlewareDispatcher.php(269): ChurchCRM\Slim\Middleware\VersionMiddleware->__invoke()
#12 /home/.../vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#13 /home/.../vendor/slim/slim/Slim/App.php(199): Slim\MiddlewareDispatcher->handle()
#14 /home/.../vendor/slim/slim/Slim/App.php(183): Slim\App->handle()
#15 /home/.../session/index.php(91): Slim\App->run()

Additional context

The installation is running on a CPanel hosting.

OluwaninsolaAO commented 4 months ago

In addition to this, I remembered this same error popped up when trying to try the demo on Softaculous as well.

DAcodedBEAT commented 4 months ago

@OluwaninsolaAO I was not able to reproduce this on https://softaculous.com/demos/churchcrm .

Can you please provide what line the error Call to undefined method ChurchCRM\Authentication\Requests\LocalUsernamePasswordRequest::getQueryParams() occurred on and, if possible, the entire log message?

OluwaninsolaAO commented 4 months ago

@DAcodedBEAT

Slim Application Error

The application could not run because of the following error:

Details

Trace

#0 /home/vendor/slim/slim/Slim/Handlers/Strategies/RequestResponse.php(38): beginSession()
#1 /home/vendor/slim/slim/Slim/Routing/Route.php(358): Slim\Handlers\Strategies\RequestResponse->__invoke()
#2 /home/vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\Routing\Route->handle()
#3 /home/vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\MiddlewareDispatcher->handle()
#4 /home/vendor/slim/slim/Slim/Routing/Route.php(315): Slim\MiddlewareDispatcher->handle()
#5 /home/vendor/slim/slim/Slim/Routing/RouteRunner.php(68): Slim\Routing\Route->run()
#6 /home/vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php(76): Slim\Routing\RouteRunner->handle()
#7 /home/vendor/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Middleware\ErrorMiddleware->process()
#8 /home/vendor/slim/slim/Slim/Middleware/RoutingMiddleware.php(45): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#9 /home/vendor/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Middleware\RoutingMiddleware->process()
#10 /home/ChurchCRM/Slim/Middleware/VersionMiddleware.php(14): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#11 /home/vendor/slim/slim/Slim/MiddlewareDispatcher.php(269): ChurchCRM\Slim\Middleware\VersionMiddleware->__invoke()
#12 /home/vendor/slim/slim/Slim/MiddlewareDispatcher.php(65): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#13 /home/vendor/slim/slim/Slim/App.php(199): Slim\MiddlewareDispatcher->handle()
#14 /home/vendor/slim/slim/Slim/App.php(183): Slim\App->handle()
#15 /home/session/index.php(91): Slim\App->run()
#16 {main}
Gnerdy commented 4 months ago

How do I ensure PSR request does not get overwritten when loggin in

OluwaninsolaAO commented 4 months ago

@Gnerdy check the linked PR to see the fix, effect the changes on your server and you are good to go.

Gnerdy commented 4 months ago

Author

Thanks very much...