Merge pull request #6580 from rxu/ticket/17117

[ticket/17117] Do not load non-existent/disabled notification methods
This commit is contained in:
Marc Alexander 2024-01-02 16:47:49 +01:00
commit c4642d2502
No known key found for this signature in database
GPG key ID: 50E0D2423696F995
2 changed files with 14 additions and 2 deletions

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);
}
}

View file

@ -159,5 +159,12 @@
<value>notification.method.board</value>
<value>0</value>
</row>
<row>
<value>notification.type.bookmark</value>
<value>0</value>
<value>3</value>
<value>notification.method.nonexistent</value>
<value>1</value>
</row>
</table>
</dataset>