PHP 8.2. interpolation deprecations: Using ${var} in strings is deprecated

Created on 7 October 2024, 7 months ago

Problem/Motivation

Deprecation notices appearing when using PHP 8.2, pertaining to var interpolation in strings.

🐛 Bug report
Status

Active

Version

3.2

Component

Code

Created by

🇬🇧United Kingdom mrhorse

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

Comments & Activities

  • Issue created by @mrhorse
  • @mrhorse opened merge request.
  • 🇬🇧United Kingdom mrhorse
  • 🇬🇧United Kingdom mrhorse
  • create patch from MR #2 to use in composer file

  • Issue was unassigned.
  • Status changed to Needs review 5 months ago
  • 🇧🇷Brazil gfbarbosa

    MR tested here and works fine!

  • Status changed to RTBC about 1 month ago
  • 🇬🇧United Kingdom aps-andrew

    I think there are still a few instances that need fixing, I found these notices after trying to run the update script

    Deprecated: Using ${var} in strings is deprecated, use {$var} instead in /var/www/html/web/modules/contrib/opigno_learning_path/src/Controller/LearningPathAchievementController.php on line 804

    $selector = "#module_panel_${training_id}_${course_id}_${module_id}";

    Deprecated: Using ${var} in strings is deprecated, use {$var} instead in /var/www/html/web/modules/contrib/opigno_learning_path/src/Controller/LearningPathAchievementController.php on line 826

    $selector = "#module_panel_${training_id}_${module_id}";

Production build 0.71.5 2024