public OperationResult <Provider[]> GetAllProviders() { return(InvokeOperations.InvokeOperation(() => { Logger.Trace("Get all providers"); var providers = signalServiceRepository.GetAllProviders(); var providersResult = new List <Provider>(providers.Length); providersResult.AddRange(providers.Select(signalProvider => new Provider { AccountId = signalProvider.id, IsSubscribe = false, Login = signalProvider.login, Nickname = signalProvider.nickname })); return providersResult.ToArray(); })); }