Problem/Motivation
I happen to be updating what contribs I can for a site on Drupal 8.9 (due to client restrictions). The 2.0.1 version and 2.1.x versions of this module are marked as compatible with Drupal ^8.7.7 but throw this fatal error, on any URL path I think:
TypeError: Argument 1 passed to Drupal\httpswww\EventSubscriber\HttpsWwwRedirectSubscriber::redirect() must be an instance of Symfony\Component\HttpKernel\Event\RequestEvent, instance of Symfony\Component\HttpKernel\Event\GetResponseEvent given in Drupal\httpswww\EventSubscriber\HttpsWwwRedirectSubscriber->redirect() (line 54 of /app/web/modules/contrib/httpswww/src/EventSubscriber/HttpsWwwRedirectSubscriber.php)
Proposed resolution
A brief search indicates this is a Symfony API change so probably just drop Drupal core 8.x compatibility in future releases.
Comments
Comment #2
enzipher commentedThanks for the report!
You are totally right about that.
GetResponseEventwas removed in Symfony 5.0 and Drupal 9.1.0 as far as I can tell.I agree with the proposed solution to raise the Drupal core requirements as those older versions are no longer supported.
Thanks,
Comment #5
niharika.s commented