summaryrefslogtreecommitdiff
path: root/src/modules/m_nicklock.cpp
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2016-03-29 12:54:02 +0200
committerAttila Molnar <attilamolnar@hush.com>2016-03-29 12:54:02 +0200
commit4aed5846f17b15939aaf620ee4c4ca95a10609fc (patch)
tree2ef9b2e003acc6a2b695b0ee1aefda0870ea0c0c /src/modules/m_nicklock.cpp
parentda2b0ee6cad139804442a1ebcd0448755714f22a (diff)
Simplify GetRouting() methods doing unicast
Diffstat (limited to 'src/modules/m_nicklock.cpp')
-rw-r--r--src/modules/m_nicklock.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/modules/m_nicklock.cpp b/src/modules/m_nicklock.cpp
index a517e95ac..35845c8d8 100644
--- a/src/modules/m_nicklock.cpp
+++ b/src/modules/m_nicklock.cpp
@@ -78,10 +78,7 @@ class CommandNicklock : public Command
RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters)
{
- User* dest = ServerInstance->FindNick(parameters[0]);
- if (dest)
- return ROUTE_OPT_UCAST(dest->server);
- return ROUTE_LOCALONLY;
+ return ROUTE_OPT_UCAST(parameters[0]);
}
};
@@ -128,10 +125,7 @@ class CommandNickunlock : public Command
RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters)
{
- User* dest = ServerInstance->FindNick(parameters[0]);
- if (dest)
- return ROUTE_OPT_UCAST(dest->server);
- return ROUTE_LOCALONLY;
+ return ROUTE_OPT_UCAST(parameters[0]);
}
};