DefaultSmsProvider::send() dispatches post-process events multiple times

Created on 15 January 2017, about 8 years ago
Updated 1 March 2025, 6 days ago

Problem Definition

The DefaultSmsProvider::send() is dispatching the SmsEvents::MESSAGE_OUTGOING_POST_PROCESSand SmsEvents::MESSAGE_POST_PROCESS multiple times for each invocation of the ::send() method. This is not consistent with the other post process events in ::queue() and ::incoming() where the post process is invoked once per method call.

Resolution

Move the event dispatching code outside the foreach loop so it runs only once.

🐛 Bug report
Status

Closed: outdated

Version

1.0

Component

Core Framework

Created by

🇳🇬Nigeria almaudoh

Live updates comments and jobs are added and updated live.
  • Needs documentation

    A documentation change is requested elsewhere. For Drupal core (and possibly other projects), once the change has been committed, this status should be recorded in a change record node.

  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024