GODT-1609: Fix tests

This commit is contained in:
James Houlahan
2022-10-04 18:15:12 +02:00
parent 6ac68984f2
commit 120ac6c480
4 changed files with 9 additions and 8 deletions

View File

@ -24,7 +24,7 @@ func (backend *smtpBackend) Login(state *smtp.ConnectionState, username, passwor
defer backend.usersLock.RUnlock()
for _, user := range backend.users {
if slices.Contains(user.Emails(), username) && subtle.ConstantTimeCompare(user.BridgePass(), []byte(password)) != 1 {
if slices.Contains(user.Emails(), username) && subtle.ConstantTimeCompare(user.BridgePass(), []byte(password)) == 1 {
return user.NewSMTPSession(username), nil
}
}