Error when loading config page

Created on 13 April 2023, almost 2 years ago
Updated 18 April 2023, almost 2 years ago

Problem/Motivation

Going to /admin/config/system/limit_domain_access_by_role, I get this error:

The website encountered an unexpected error. Please try again later.
TypeError: Drupal\limit_domain_access_by_role\Form\LimitDomainAccessByRoleConfigForm::__construct(): Argument #2 ($database) must be of type Drupal\Core\Database\Driver\mysql\Connection, Drupal\mysql\Driver\Database\mysql\Connection given, called in /var/www/web/modules/contrib/limit_domain_access_by_role/src/Form/LimitDomainAccessByRoleConfigForm.php on line 97 in Drupal\limit_domain_access_by_role\Form\LimitDomainAccessByRoleConfigForm->__construct() (line 68 of modules/contrib/limit_domain_access_by_role/src/Form/LimitDomainAccessByRoleConfigForm.php).

Steps to reproduce

- Install Drupal core 9.5.7 with Standard profile
- Install this module version 1.5.0
- Visit /admin/config/system/limit_domain_access_by_role to observe error.

🐛 Bug report
Status

RTBC

Version

1.5

Component

Code

Created by

🇺🇸United States krisahil

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @krisahil
  • @krisahil opened merge request.
  • Status changed to Needs review almost 2 years ago
  • 🇮🇳India Raveen Kumar

    @krisahil, The MR looks working fine. I have installed this module on Drupal 9.5 And the same error was showing up for me like yours. My PHP version is 8.1. I am attaching my error log, before the patch, & after the patch applied screenshots for reference. Please have a look. And Thank you.

  • Status changed to RTBC almost 2 years ago
  • 🇵🇭Philippines kenyoOwen

    Hi krisahil

    I applied your MR !1 in my local with Drupal 9.5.7, it worked for me the issue is now resolved.

    Please look at the screenshots attached for your reference.

    For your review.
    Thank you.

Production build 0.71.5 2024