Empty emails are being sent to the user who created the message


Description

Empty emails are being sent to the user who created the message

Steps to Reproduce

[This is a difficult one to reproduce] Below are the steps to simulate the user logged out situation

1) Login to any instnace as two different users (user1 and user2)
2) Initiate a connect converstation between the two users.
3) On User 1 machine, set the network to slow using dev tools.
4) In an other window, acceess sys_user_presence table and filter out user1's record.
5) Send multiple messages from user1 and user2 in quick intervals.
6) Delete sys_user_presence record from step 4 [To simulate the user offile situation]

Expected : There should not be any emails triggered to the User 1 as he sent the messages
Actual : There are emails triggered to the person(user1) who sent the messages

Workaround

Unfortunately, there is no workaround being present for this issue:
The instance needs to be upgraded to San Diego once it is being available.


Related Problem: PRB1507666