Fix deprecated PHP 8.2 function: strtolower(): Passing null to parameter #1 ($string) of type string is deprecated when embedding a media in CKEditor

Created on 20 February 2024, about 1 year ago
Updated 16 April 2024, about 1 year ago

Problem/Motivation

The module has deprecated functions with php 8.2:
Deprecated function: strtolower(): Passing null to parameter #1 ($string) of type string is deprecated

Steps to reproduce

Try to embed media then you will get the error.

Proposed resolution

Use strtolower($provider ?? '')

Remaining tasks

  • ✅ File an issue about this project
  • ✅ Addition/Change/Update/Fix to this project
  • ✅ Testing to ensure no regression
  • ➖ Automated unit/functional testing coverage
  • ➖ Developer Documentation support on feature change/addition
  • ➖ User Guide Documentation support on feature change/addition
  • ➖ UX/UI designer responsibilities
  • ➖ Accessibility and Readability
  • ✅ Code review from 1 Varbase core team member
  • ✅ Full testing and approval
  • ✅ Credit contributors
  • ✅ Review with the product owner
  • ✅ Update Release Notes and Update Helper on new feature change/addition
  • ✅ Release varbase-10.0.0-rc2 , varbase-9.1.2 , varbase_media-9.1.6 , varbase_media-9.0.42 , varbase_media-10.0.0-rc2

Varbase update type

  • ✅ No Update
  • ➖ Optional Update
  • ➖ Forced Update
  • ➖ Forced Update if Unchanged

User interface changes

  • N/A

API changes

  • N/A

Data model changes

  • N/A

Release notes snippet

  • Issue #3422776 by n.ghunaim : Fixed deprecated PHP 8.2 function: strtolower(): Passing null to parameter #1 ($string) of type string is deprecated when embedding a media in CKEditor
🐛 Bug report
Status

Fixed

Version

9.1

Component

Code

Created by

🇯🇴Jordan n.ghunaim Amman - Jordan

Live updates comments and jobs are added and updated live.
  • PHP 8.2

    The issue particularly affects sites running on PHP version 8.2.0 or later.

Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024