Problem/Motivation

After update to PHP 8.2 there is the following message:
Deprecated function: Creation of dynamic property Drupal\administration_language_negotiation\AdministrationLanguageNegotiationConditionManager::$cacheKeyPrefix is deprecated in Drupal\administration_language_negotiation\AdministrationLanguageNegotiationConditionManager->__construct() (line 49 of modules/contrib/administration_language_negotiation/src/AdministrationLanguageNegotiationConditionManager.php).

Steps to reproduce

Go to `/admin/config/regional/language/detection/administration_language`

Proposed resolution

Declare $cacheKeyPrefix as protected string like Core language module LanguageNegotiationMethodManager class does.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

pakmanlh created an issue. See original summary.

pakmanlh’s picture

Status: Active » Needs review

  • Pol committed 282c3630 on 2.x authored by pakmanlh
    Issue #3366786: Deprecated function: Creation of dynamic property
    
pol’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

eason xu’s picture

pol’s picture

Dear Eason,

Can you explain what is this patch and why you posted it here in a closed issue ?

eason xu’s picture

Dear Pol,

Don't worry about this, it's just because I still encounter this problem in the version I am using, and there is no need to open a new issue .

steveoriol’s picture

This patch need to be apply to the current branch "2.0.0", not only for the dev one.

anybody’s picture

I tagged a new 2.0.1 release with this fix now!