nickserv: Auto-save passwords when they are set and remove the 'show' command

Passwords should be secret, so don't display them to everyone who asks.
The auto-save is there to make owine happy. ;)


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1250 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
psychon
2008-10-14 17:28:10 +00:00
parent 2216c93e40
commit 133c8fcb8a
+2 -9
View File
@@ -35,17 +35,10 @@ public:
if (sCmdName == "set") {
CString sPass = sCommand.Token(1, true);
m_sPass = sPass;
PutModule("Password set");
} else if (sCmdName == "show") {
if (m_sPass.empty())
PutModule("No password set");
else
PutModule("Current password: " + m_sPass);
} else if (sCmdName == "save") {
SetNV("Password", m_sPass);
PutModule("Saved!");
PutModule("Password set");
} else {
PutModule("Commands: set <password>, show, save");
PutModule("Commands: set <password>");
}
}