Browse Source

fix casefolding issue in NS SUSPEND DEL

NS SUSPEND DEL incorrectly required the use of the casefolded account name.
tags/v2.5.0-rc1
Shivaram Lingamneni 3 years ago
parent
commit
6a6f104899
1 changed files with 3 additions and 3 deletions
  1. 3
    3
      irc/accounts.go

+ 3
- 3
irc/accounts.go View File

@@ -1350,14 +1350,14 @@ func (am *AccountManager) killClients(clients []*Client) {
1350 1350
 	}
1351 1351
 }
1352 1352
 
1353
-func (am *AccountManager) Unsuspend(account string) (err error) {
1354
-	cfaccount, err := CasefoldName(account)
1353
+func (am *AccountManager) Unsuspend(accountName string) (err error) {
1354
+	cfaccount, err := CasefoldName(accountName)
1355 1355
 	if err != nil {
1356 1356
 		return errAccountDoesNotExist
1357 1357
 	}
1358 1358
 
1359 1359
 	existsKey := fmt.Sprintf(keyAccountExists, cfaccount)
1360
-	suspensionKey := fmt.Sprintf(keyAccountSuspended, account)
1360
+	suspensionKey := fmt.Sprintf(keyAccountSuspended, cfaccount)
1361 1361
 	err = am.server.store.Update(func(tx *buntdb.Tx) error {
1362 1362
 		_, err := tx.Get(existsKey)
1363 1363
 		if err != nil {

Loading…
Cancel
Save