Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Added versions to /map as requested by fraggeln #467

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
3 participants
Contributor

Justasic commented Apr 3, 2013

Title says it all. I am only doing for 2.2 since it's a core command change

@SaberUK SaberUK and 1 other commented on an outdated diff Apr 3, 2013

src/commands/cmd_map.cpp
@@ -45,7 +45,8 @@ CmdResult CommandMap::Handle (const std::vector<std::string>&, User *user)
if (IS_OPER(user))
{
- user->WriteNumeric(006, "%s :%s [%s]", user->nick.c_str(), ServerInstance->Config->ServerName.c_str(), ServerInstance->Config->GetSID().c_str());
+ std::string version = ServerInstance->GetVersionString(IS_OPER(user));
@SaberUK

SaberUK Apr 3, 2013

Contributor

If this code is being executed then the user is an oper so you can just pass true here.

@Justasic

Justasic Apr 3, 2013

Contributor

oh, alright. I copied and pasted and didnt know if IS_OPER returned the user (because it was a macro?) or a boolean so I just left it as is.. I'll fix in a few mins here..

Owner

attilamolnar commented Jul 6, 2013

This does not change the "real" /map in spanningtree, so it has no effect when spanningtree is loaded.
If you have the time then change that, test with multiple servers and reopen.

Side note: Most information coming from GetVersionString(true) is not synchronized currently: spanningtree calls GetVersionString(false) when sending VERSION.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment