Deprecated function: explode(): Passing null to parameter #2 ($string) of type string is deprecated in salesforce_webform

Created on 5 May 2023, over 1 year ago
Updated 3 August 2023, over 1 year ago

Problem/Motivation

Getting the following php message in the log when adding a webform element to the Salesforce mapping.

Deprecated function: explode(): Passing null to parameter #2 ($string) of type string is deprecated in Drupal\salesforce_webform\Plugin\SalesforceMappingField\WebformElements->getPluginDefinition() (line 107 of /var/www/html/repos/salesforce/modules/salesforce_webform/src/Plugin/SalesforceMappingField/WebformElements.php)

Steps to reproduce

  1. Go to map fields /admin/structure/salesforce/mappings/manage/[mapping name]/fields
  2. Under Field Type, select webform element
  3. Check logs for deprecation message.

Proposed resolution

Prevent passing null to explode.

Remaining tasks

🐛 Bug report
Status

Fixed

Version

5.0

Component

salesforce_webform.module

Created by

🇺🇸United States capysara

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

Comments & Activities

Production build 0.71.5 2024