summaryrefslogtreecommitdiff
path: root/src/account-server/accounthandler.cpp
diff options
context:
space:
mode:
authorYohann Ferreira <bertram@cegetel.net>2008-04-25 23:58:53 +0000
committerYohann Ferreira <bertram@cegetel.net>2008-04-25 23:58:53 +0000
commit19d8859a9c997591d8e0fbbda745da7258104eee (patch)
treea8088ed44a64900bd7b78db2ba56439d0110702b /src/account-server/accounthandler.cpp
parent5b967eff8c94ba383f2c8b09ddacf4653f571f77 (diff)
downloadmanaserv-19d8859a9c997591d8e0fbbda745da7258104eee.tar.gz
manaserv-19d8859a9c997591d8e0fbbda745da7258104eee.tar.bz2
manaserv-19d8859a9c997591d8e0fbbda745da7258104eee.tar.xz
manaserv-19d8859a9c997591d8e0fbbda745da7258104eee.zip
Realigned Email already exists error return value and removed GetEmail Address
Diffstat (limited to 'src/account-server/accounthandler.cpp')
-rw-r--r--src/account-server/accounthandler.cpp25
1 files changed, 1 insertions, 24 deletions
diff --git a/src/account-server/accounthandler.cpp b/src/account-server/accounthandler.cpp
index 5083758d..871d1685 100644
--- a/src/account-server/accounthandler.cpp
+++ b/src/account-server/accounthandler.cpp
@@ -408,7 +408,7 @@ static void handleEmailChangeMessage(AccountClient &computer, MessageIn &msg)
}
else if (storage->doesEmailAddressExist(emailHash))
{
- reply.writeByte(EMAILCHG_EXISTS_EMAIL);
+ reply.writeByte(ERRMSG_EMAIL_ALREADY_EXISTS);
}
else
{
@@ -420,24 +420,6 @@ static void handleEmailChangeMessage(AccountClient &computer, MessageIn &msg)
computer.send(reply);
}
-static void handleEmailGetMessage(AccountClient &computer)
-{
- MessageOut reply(APMSG_EMAIL_GET_RESPONSE);
-
- Account *acc = computer.getAccount();
- if (!acc)
- {
- reply.writeByte(ERRMSG_NO_LOGIN);
- computer.send(reply);
- return;
- }
-
- reply.writeByte(ERRMSG_OK);
- reply.writeString(acc->getEmail());
-
- computer.send(reply);
-}
-
static void handlePasswordChangeMessage(AccountClient &computer, MessageIn &msg)
{
std::string oldPassword = msg.readString();
@@ -754,11 +736,6 @@ void AccountHandler::processMessage(NetComputer *comp, MessageIn &message)
handleEmailChangeMessage(computer, message);
break;
- case PAMSG_EMAIL_GET:
- LOG_DEBUG("Received msg ... PAMSG_EMAIL_GET");
- handleEmailGetMessage(computer);
- break;
-
case PAMSG_PASSWORD_CHANGE:
LOG_DEBUG("Received msg ... PAMSG_PASSWORD_CHANGE");
handlePasswordChangeMessage(computer, message);