From 829709f07a16e945af416cb1df23d0fcefdba8e0 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 4 Jan 2015 18:54:18 +0300 Subject: eathena: allow delete characters if account have non default email. --- src/net/eathena/charserverhandler.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/net/eathena/charserverhandler.cpp') diff --git a/src/net/eathena/charserverhandler.cpp b/src/net/eathena/charserverhandler.cpp index 5ced3761f..c2292abde 100644 --- a/src/net/eathena/charserverhandler.cpp +++ b/src/net/eathena/charserverhandler.cpp @@ -285,7 +285,8 @@ void CharServerHandler::newCharacter(const std::string &name, const int slot, outMsg.writeInt16(static_cast(race), "race"); } -void CharServerHandler::deleteCharacter(Net::Character *const character) +void CharServerHandler::deleteCharacter(Net::Character *const character, + const std::string &email) { if (!character) return; @@ -294,7 +295,10 @@ void CharServerHandler::deleteCharacter(Net::Character *const character) createOutPacket(CMSG_CHAR_DELETE); outMsg.writeInt32(mSelectedCharacter->dummy->getId(), "id?"); - outMsg.writeString("a@a.com", 40, "email"); + if (email.empty()) + outMsg.writeString("a@a.com", 40, "email"); + else + outMsg.writeString(email, 40, "email"); } void CharServerHandler::switchCharacter() const -- cgit v1.2.3-70-g09d2