From 3ea280c82a053e876a07e587515a4699069cca00 Mon Sep 17 00:00:00 2001 From: Pavel Vesely Date: Mon, 6 Jul 2020 15:27:35 +0200 Subject: [PATCH 1/2] Motification changes UNDO --- Oqtane.Server/Infrastructure/Jobs/NotificationJob.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Oqtane.Server/Infrastructure/Jobs/NotificationJob.cs b/Oqtane.Server/Infrastructure/Jobs/NotificationJob.cs index 93127ff5..520533d9 100644 --- a/Oqtane.Server/Infrastructure/Jobs/NotificationJob.cs +++ b/Oqtane.Server/Infrastructure/Jobs/NotificationJob.cs @@ -38,10 +38,8 @@ namespace Oqtane.Infrastructure List sites = siteRepository.GetSites().ToList(); foreach (Site site in sites) { - List notifications = notificationRepository.GetNotifications(site.SiteId, -1, -1).ToList(); - if (!notifications.Any()) continue; //Nothing to do. - log += "Processing Notifications For Site: " + site.Name + "\n\n"; + // get site settings List sitesettings = settingRepository.GetSettings(EntityNames.Site, site.SiteId).ToList(); Dictionary settings = GetSettings(sitesettings); @@ -63,6 +61,7 @@ namespace Oqtane.Infrastructure // iterate through notifications int sent = 0; + List notifications = notificationRepository.GetNotifications(site.SiteId, -1, -1).ToList(); foreach (Notification notification in notifications) { MailMessage mailMessage = new MailMessage(); From a083405b4881a1f3d1fde3881f6618fae8be0431 Mon Sep 17 00:00:00 2001 From: Alexander Hendel Date: Tue, 7 Jul 2020 09:56:24 +0200 Subject: [PATCH 2/2] Fix directory seperator in InstallationManager --- Oqtane.Server/Infrastructure/InstallationManager.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Oqtane.Server/Infrastructure/InstallationManager.cs b/Oqtane.Server/Infrastructure/InstallationManager.cs index c6467c20..f9a6f01c 100644 --- a/Oqtane.Server/Infrastructure/InstallationManager.cs +++ b/Oqtane.Server/Infrastructure/InstallationManager.cs @@ -88,7 +88,7 @@ namespace Oqtane.Infrastructure // deploy to appropriate locations foreach (ZipArchiveEntry entry in archive.Entries) { - string foldername = Path.GetDirectoryName(entry.FullName).Split('\\')[0]; + string foldername = Path.GetDirectoryName(entry.FullName).Split(Path.DirectorySeparatorChar)[0]; string filename = Path.GetFileName(entry.FullName); switch (foldername) @@ -98,7 +98,7 @@ namespace Oqtane.Infrastructure ExtractFile(entry, filename); break; case "wwwroot": - filename = Path.Combine(webRootPath, Utilities.PathCombine(entry.FullName.Replace("wwwroot/", "").Split('/'))); + filename = Path.Combine(webRootPath, Utilities.PathCombine(entry.FullName.Replace($"wwwroot{Path.DirectorySeparatorChar}", "").Split(Path.DirectorySeparatorChar))); ExtractFile(entry, filename); break; }