diff options
| author | 2010-08-27 21:40:06 -0400 | |
|---|---|---|
| committer | 2010-08-27 21:40:06 -0400 | |
| commit | 4fa17de4ccc01c210bbd4b6fac3b15ccab8315f9 (patch) | |
| tree | bb5097c92a1d2d9f8f9bac23c25b3442af3ed324 /src/users.cpp | |
| parent | Add some documentation about sqlauth and an example (diff) | |
| download | inspircd++-4fa17de4ccc01c210bbd4b6fac3b15ccab8315f9.tar.gz inspircd++-4fa17de4ccc01c210bbd4b6fac3b15ccab8315f9.tar.bz2 inspircd++-4fa17de4ccc01c210bbd4b6fac3b15ccab8315f9.zip | |
Promote PopulateInfoMap to core, it is moderately useful
Diffstat (limited to 'src/users.cpp')
| -rw-r--r-- | src/users.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/users.cpp b/src/users.cpp index e4d89afc7..2ee6c82e4 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -1690,6 +1690,18 @@ void User::PurgeEmptyChannels() this->UnOper(); } +void User::PopulateInfoMap(SubstMap& userinfo) +{ + GetIPString(); // populate cachedip + userinfo["nick"] = nick; + userinfo["host"] = host; + userinfo["ip"] = cachedip; + userinfo["gecos"] = fullname; + userinfo["ident"] = ident; + userinfo["server"] = server; + userinfo["uuid"] = uuid; +} + const std::string& FakeUser::GetFullHost() { if (!ServerInstance->Config->HideWhoisServer.empty()) |
