[ticket/17117] Do not load non-existent/disabled notification methods

Non-existent or disabled notification methods (f.e. added
by extensions which were later disabled/purged) should not be loaded.

PHPBB3-17117
This commit is contained in:
rxu 2024-01-02 01:33:13 +07:00
parent 565053f508
commit f31ea59a1a
No known key found for this signature in database
GPG key ID: 955F0567380E586A

View file

@ -411,12 +411,17 @@ class manager
foreach ($methods as $method)
{
// setup the notification methods and add the notification to the queue
// Do not load non-existent notification methods
if (!isset($this->notification_methods[$method]))
{
continue;
}
// Setup the notification methods and add the notification to the queue
if (!isset($notification_methods[$method]))
{
$notification_methods[$method] = $this->get_method_class($method);
}
$notification_methods[$method]->add_to_queue($notification);
}
}