diff --git a/gpas.go b/gpas.go index 5bf1a05..31cc7bd 100644 --- a/gpas.go +++ b/gpas.go @@ -79,7 +79,7 @@ func passwordLost(user User, config *ConfigFile, ldapConn *ldap.Conn) error { log.Printf(fmt.Sprintf("passwordLost (Check existing invitation) : %v", searchRes.Entries[0])) return err } - if len(searchRes.Entries == 0) { + if len(searchRes.Entries) == 0 { /* Add the invitation */ addReq := ldap.NewAddRequest( user.DN,