Problem/Motivation

In core/modules/locale/locale.module, $language_list variable never used.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

shetpooja04 created an issue. See original summary.

shetpooja04’s picture

Assigned: shetpooja04 » Unassigned
Status: Active » Needs review
FileSize
664 bytes
937.4 KB
895.94 KB

Commit ID: 91fc0d3e (screenshot attached: used_language_list)

Link: https://git.drupalcode.org/project/drupal/-/commit/91fc0d3ed91b263940b758588e416f78fd838d26

For Issue: https://www.drupal.org/project/drupal/issues/1905152 the changes were made

File: core/modules/locale/locale.module

$language_list was getting used in above mentioned commit in below code

// Delete configuration translations.
    \Drupal\locale\Locale::config()->deleteComponentTranslations($components, array_keys($language_list));

later in the below commit the line was removed
Commit ID: c34478f5 (screenshot attached : unused_language_list)

Link: https://git.drupalcode.org/project/drupal/-/commit/c34478f5e71a49d7b9af649ed87119367de17a01

For Issue: https://www.drupal.org/project/drupal/issues/2212069 the changes were made

File: core/modules/locale/locale.module

anu.a_95’s picture

Applied Patch #2 successfully

Unused variable $language_list in the locale.module is removed by applying the patch. The Drupal instance worked as normal after applying the patch.

anu.a_95’s picture

Status: Needs review » Reviewed & tested by the community

  • catch committed dcc53b3 on 9.1.x
    Issue #3168261 by shetpooja04: Remove unused variable $language_list in...
catch’s picture

Status: Reviewed & tested by the community » Fixed

Thanks for the research in #2, definitely leftover cruft.

Committed dcc53b3 and pushed to 9.1.x. Thanks!

Status: Fixed » Closed (fixed)

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