User notification delegates are added as recipient before evaluating the filter conditions on the sys_notif_subscription record.
Users excluded due to personal subscription notification filter can still delegate, and the delegates still receive notifications.
Steps to Reproduce
- Create a "Subscribable" notification on the incident table with no condition.
2. Add a delegate to User1.
3. Add a subscription for User1 and add a filter like short description starts with "Test delegate".
4. Create an incident with Short description "Test 123".
5. Check the notification created on the sent mailbox
You will see the email is sent and the delegate is included in recipient but user1 is excluded because personal subscription filter condition failed.
Notification 'Testing delegates' (6e3b05b1db4XX0e87c92dadb9619be) excluded recipients because user's notification preference "Filter" filtered it (see "cmn_notif_message.notification_filter"): 'Prabhat Kuchibhotla' (6093cXXX07de090c7db9619a1)
Notification 'Testing delegates' (6e3b05b1db4b4700e87c92dadb9619be) included recipients as a delegate of another recipient (see "Delegates"): 'System Administrator' (6816f79cc0a80XXa33be04be441), 'ITIL User' (a19d3ca0db8bXXX07de090c7db9619e9) EMAIL.67af0175db8b47007de090c7db9619e8
The delegates can set personal subscription filters to avoid these notifications from being received or the delegates can be removed from the original user.
Related Problem: PRB1245551