Skip to content

[5.1] Deprecation warning in mod_languages when inside an error page #43293

@Chaosxmk

Description

@Chaosxmk

Steps to reproduce the issue

Install Joomla 5.1 or upgrade to 5.1
Create a bilingual site
Create an instance of mod_languages in a position that exists also on an error page
In global configuration, set error reporting to maximum
Navigate to a url that will produce an error

Expected result

The module works correctly

Actual result

This warning message is displayed:

Deprecated: strtolower(): Passing null to parameter #1 ($string) of type string is deprecated in /home/gdwtest2/domains/gdwtest2.geantduweb.ca/public_html/libraries/src/Extension/ExtensionManagerTrait.php on line 45

Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/gdwtest2/domains/gdwtest2.geantduweb.ca/public_html/modules/mod_languages/src/Helper/LanguagesHelper.php on line 79

Additional comments

I've tested this in both a freshly created site and a site that was upgraded to 5.1, the error occurs either way.

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions