getThirdPartySettings() doesn't return anything, even though it's interface declares that it will

Created on 20 March 2024, 6 months ago
Updated 20 April 2024, 5 months ago

Problem/Motivation

Drupal\webform\WebformThirdPartySettingsManager::getThirdPartySettings() doesn't return anything, even though in it's interface: Drupal\Core\Config\Entity\ThirdPartySettingsInterface, it states it will return an array.

Steps to reproduce

  1. Set some third party setting(s) for a custom module, e.g. \Drupal::service('webform.third_party_settings_manager')->setThirdPartySetting('my_module_name', 'my_setting_key', 'my_setting_value');
  2. Try and retrieve all settings at once, calling getThirdPartySettings() - e.g. $settings = \Drupal::service('webform.third_party_settings_manager')->getThirdPartySettings('my_module_name');
  3. Because the function doesn't return anything (even though the interface says it will), $settings will be null.

Proposed resolution

Return the result from within getThirdPartySettings().

Remaining tasks

MR to follow shortly.

User interface changes

N/A

API changes

getThirdPartySettings() will return what it's interface declaration specifies it will return.

Data model changes

N/A

πŸ› Bug report
Status

Fixed

Version

6.2

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom rossb89 Bristol

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

Merge Requests

Comments & Activities

Production build 0.71.5 2024