From 85f1660b394957f40c48b88822a0187cf57fedb4 Mon Sep 17 00:00:00 2001 From: SuhorukovAnton Date: Wed, 19 Jan 2022 13:46:21 +0300 Subject: [PATCH] analizators/U2U1203 --- common/ASC.Core.Common/Context/Impl/AuthorizationManager.cs | 2 +- common/ASC.Data.Backup.Core/Tasks/DeletePortalTask.cs | 2 +- products/ASC.Files/Core/Core/FileStorageService.cs | 2 +- web/ASC.Web.Core/QuotaSync.cs | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/common/ASC.Core.Common/Context/Impl/AuthorizationManager.cs b/common/ASC.Core.Common/Context/Impl/AuthorizationManager.cs index 5f0e9609f55..87ef0515ba0 100644 --- a/common/ASC.Core.Common/Context/Impl/AuthorizationManager.cs +++ b/common/ASC.Core.Common/Context/Impl/AuthorizationManager.cs @@ -100,7 +100,7 @@ public void RemoveAce(AzRecord r) public void RemoveAllAces(ISecurityObjectId id) { - foreach (var r in GetAces(Guid.Empty, Guid.Empty, id).ToArray()) + foreach (var r in GetAces(Guid.Empty, Guid.Empty, id)) { RemoveAce(r); } diff --git a/common/ASC.Data.Backup.Core/Tasks/DeletePortalTask.cs b/common/ASC.Data.Backup.Core/Tasks/DeletePortalTask.cs index 5cc08414418..2888a72d7b4 100644 --- a/common/ASC.Data.Backup.Core/Tasks/DeletePortalTask.cs +++ b/common/ASC.Data.Backup.Core/Tasks/DeletePortalTask.cs @@ -89,7 +89,7 @@ private void DoDeleteStorage() foreach (var module in storageModules) { var storage = StorageFactory.GetStorage(ConfigPath, TenantId.ToString(), module); - var domains = StorageFactoryConfig.GetDomainList(ConfigPath, module).ToList(); + var domains = StorageFactoryConfig.GetDomainList(ConfigPath, module); foreach (var domain in domains) { ActionInvoker.Try(state => storage.DeleteFiles((string)state, "\\", "*.*", true), domain, 5, diff --git a/products/ASC.Files/Core/Core/FileStorageService.cs b/products/ASC.Files/Core/Core/FileStorageService.cs index fa4915d6a25..88f8bb0308f 100644 --- a/products/ASC.Files/Core/Core/FileStorageService.cs +++ b/products/ASC.Files/Core/Core/FileStorageService.cs @@ -1602,7 +1602,7 @@ public void ReassignStorage(Guid userFromId, Guid userToId) if (providerDao != null) { var providersInfo = providerDao.GetProvidersInfo(userFrom.ID); - var commonProvidersInfo = providersInfo.Where(provider => provider.RootFolderType == FolderType.COMMON).ToList(); + var commonProvidersInfo = providersInfo.Where(provider => provider.RootFolderType == FolderType.COMMON); //move common thirdparty storage userFrom foreach (var commonProviderInfo in commonProvidersInfo) diff --git a/web/ASC.Web.Core/QuotaSync.cs b/web/ASC.Web.Core/QuotaSync.cs index bfe2b7a48fc..de0cce7a79c 100644 --- a/web/ASC.Web.Core/QuotaSync.cs +++ b/web/ASC.Web.Core/QuotaSync.cs @@ -56,14 +56,14 @@ public void RunJob()//DistributedTask distributedTask, CancellationToken cancell var (tenantManager, storageFactoryConfig, storageFactory) = scopeClass; tenantManager.SetCurrentTenant(TenantId); - var storageModules = storageFactoryConfig.GetModuleList(string.Empty).ToList(); + var storageModules = storageFactoryConfig.GetModuleList(string.Empty); foreach (var module in storageModules) { var storage = storageFactory.GetStorage(TenantId.ToString(), module); storage.ResetQuota(""); - var domains = storageFactoryConfig.GetDomainList(string.Empty, module).ToList(); + var domains = storageFactoryConfig.GetDomainList(string.Empty, module); foreach (var domain in domains) { storage.ResetQuota(domain);