diff --git a/WebsitePanel/Database/install_db.sql b/WebsitePanel/Database/install_db.sql index e6409576..3f2cb24a 100644 --- a/WebsitePanel/Database/install_db.sql +++ b/WebsitePanel/Database/install_db.sql @@ -192,7 +192,7 @@ SELECT E.SubscriberNumber FROM ExchangeAccounts AS E -INNER JOIN ExchangeMailboxPlans AS P ON E.MailboxPlanId = P.MailboxPlanId +LEFT OUTER JOIN ExchangeMailboxPlans AS P ON E.MailboxPlanId = P.MailboxPlanId WHERE E.ItemID = @ItemID AND (E.AccountType = @AccountType OR @AccountType IS NULL) diff --git a/WebsitePanel/Database/update_db.sql b/WebsitePanel/Database/update_db.sql index d3d09146..1e76c264 100644 --- a/WebsitePanel/Database/update_db.sql +++ b/WebsitePanel/Database/update_db.sql @@ -2332,7 +2332,7 @@ SELECT E.SubscriberNumber FROM ExchangeAccounts AS E -INNER JOIN ExchangeMailboxPlans AS P ON E.MailboxPlanId = P.MailboxPlanId +LEFT OUTER JOIN ExchangeMailboxPlans AS P ON E.MailboxPlanId = P.MailboxPlanId WHERE E.ItemID = @ItemID AND (E.AccountType = @AccountType OR @AccountType IS NULL) diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/Exchange2007.cs b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/Exchange2007.cs index 60c3e411..533abfe4 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/Exchange2007.cs +++ b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/Exchange2007.cs @@ -4393,7 +4393,10 @@ namespace WebsitePanel.Providers.HostedSolution { try { - RemovePublicFolderClientPermission(runSpace, folder, @"\" + existingAccount.AccountName, existingAccount.PublicFolderPermission); + RemovePublicFolderClientPermission( runSpace, + folder, + existingAccount.AccountName.Contains("@") ? existingAccount.AccountName : @"\" + existingAccount.AccountName, + existingAccount.PublicFolderPermission); } catch (Exception) { @@ -4406,7 +4409,10 @@ namespace WebsitePanel.Providers.HostedSolution { try { - AddPublicFolderClientPermission(runSpace, folder, @"\" + newAccount.AccountName, newAccount.PublicFolderPermission); + AddPublicFolderClientPermission(runSpace, + folder, + newAccount.AccountName.Contains("@") ? newAccount.AccountName : @"\" + newAccount.AccountName, + newAccount.PublicFolderPermission); } catch (Exception) {