Fixing an issue where doing folder config on account does not refresh the folder list.

This commit is contained in:
Burak Kaan Köse
2024-08-22 01:20:08 +02:00
parent 298344c2ab
commit d060db3c96
5 changed files with 37 additions and 33 deletions

View File

@@ -19,9 +19,9 @@ using Wino.Core.Domain.Models.Folders;
using Wino.Core.Domain.Models.Synchronization;
using Wino.Core.UWP.Extensions;
using Wino.Dialogs;
using Wino.Messaging.Client.Accounts;
using Wino.Messaging.Client.Shell;
using Wino.Messaging.Server;
using Wino.Messaging.UI;
namespace Wino.Services
{
@@ -197,16 +197,13 @@ namespace Wino.Services
if (configuration != null)
{
var updatedAccount = await folderService.UpdateSystemFolderConfigurationAsync(accountId, configuration);
InfoBarMessage(Translator.SystemFolderConfigSetupSuccess_Title, Translator.SystemFolderConfigSetupSuccess_Message, InfoBarMessageType.Success);
// Update account menu item and force re-synchronization.
WeakReferenceMessenger.Default.Send(new AccountUpdatedMessage(updatedAccount));
WeakReferenceMessenger.Default.Send(new AccountFolderConfigurationUpdated(accountId));
var options = new SynchronizationOptions()
{
AccountId = updatedAccount.Id,
AccountId = accountId,
Type = SynchronizationType.Full,
};