diff --git a/src/java/davmail/caldav/CaldavConnection.java b/src/java/davmail/caldav/CaldavConnection.java index 1bb9c6b7..842e4ca5 100644 --- a/src/java/davmail/caldav/CaldavConnection.java +++ b/src/java/davmail/caldav/CaldavConnection.java @@ -886,7 +886,7 @@ public class CaldavConnection extends AbstractConnection { // actual principal is email address String actualPrincipal = principal; if ("users".equals(prefix) && - (session.getAlias().equalsIgnoreCase(principal) || session.getAliasFromLogin().equalsIgnoreCase(principal))) { + (principal.equalsIgnoreCase(session.getAlias()) || (principal.equalsIgnoreCase(session.getAliasFromLogin())))) { actualPrincipal = session.getEmail(); }