Don't return mails to non-existing characters (thanks to laviniu for finding the bug)
--HG-- branch : trunk
This commit is contained in:
@@ -375,8 +375,8 @@ void WorldSession::HandleMailReturnToSender(WorldPacket & recv_data)
|
|||||||
CharacterDatabase.CommitTransaction();
|
CharacterDatabase.CommitTransaction();
|
||||||
pl->RemoveMail(mailId);
|
pl->RemoveMail(mailId);
|
||||||
|
|
||||||
// send back only to players and simple drop for other cases
|
// only return mail if the player exists (and delete if not existing)
|
||||||
if (m->messageType == MAIL_NORMAL)
|
if (m->messageType == MAIL_NORMAL && m->sender)
|
||||||
{
|
{
|
||||||
MailDraft draft(m->subject, m->body);
|
MailDraft draft(m->subject, m->body);
|
||||||
if (m->mailTemplateId)
|
if (m->mailTemplateId)
|
||||||
|
|||||||
Reference in New Issue
Block a user