Sfoglia il codice sorgente

small refactor

tags/v2.9.0-rc1
Shivaram Lingamneni 2 anni fa
parent
commit
a57bf46e6a
1 ha cambiato i file con 2 aggiunte e 4 eliminazioni
  1. 2
    4
      irc/nickserv.go

+ 2
- 4
irc/nickserv.go Vedi File

@@ -1146,7 +1146,6 @@ func nsConfirmPassword(server *Server, account, passphrase string) (errorMessage
1146 1146
 func nsPasswdHandler(service *ircService, server *Server, client *Client, command string, params []string, rb *ResponseBuffer) {
1147 1147
 	var target string
1148 1148
 	var newPassword string
1149
-	var checkPassword string
1150 1149
 	var errorMessage string
1151 1150
 
1152 1151
 	var oper *Oper
@@ -1172,10 +1171,9 @@ func nsPasswdHandler(service *ircService, server *Server, client *Client, comman
1172 1171
 			newPassword = ""
1173 1172
 		}
1174 1173
 
1175
-		// fix #1883 Nickserv gives error when user attempt to change password to *
1176
-		checkPassword = params[2]
1174
+		checkPassword := params[2]
1177 1175
 		if checkPassword == "*" {
1178
-			checkPassword = ""
1176
+			checkPassword = "" // #1883
1179 1177
 		}
1180 1178
 
1181 1179
 		if target == "" {

Loading…
Annulla
Salva