Compare commits

..

No commits in common. "d872382f196ed5ae4e28f297e7ded7b0d8d6cee3" and "3f15ef9b4c3bdfeccc12694414f1efc74f1eca04" have entirely different histories.

1 changed files with 3 additions and 5 deletions

View File

@ -120,15 +120,15 @@ namespace AyCode.Blazor.Components.Services
{ {
return GetAllAsync<List<T>>(messageTag, response => return GetAllAsync<List<T>>(messageTag, response =>
{ {
intoList.Clear();
if (response.Status != SignalResponseStatus.Success || response.ResponseData == null) if (response.Status != SignalResponseStatus.Success || response.ResponseData == null)
{ {
Logger.Error($"GetAllIntoAsync<{typeof(T).Name}>(); status: {response.Status}; dataCount: {response.ResponseData?.Count}; {ConstHelper.NameByValue(TagsName, messageTag)};"); Logger.Error($"GetAllIntoAsync<{typeof(T).Name}>(); status: {response.Status}; dataCount: {response.ResponseData?.Count}; {ConstHelper.NameByValue(TagsName, messageTag)};");
return Task.CompletedTask; return Task.CompletedTask;
} }
intoList.Clear();
intoList.AddRange(response.ResponseData); intoList.AddRange(response.ResponseData);
return Task.CompletedTask; return Task.CompletedTask;
}, contextParams); }, contextParams);
} }
@ -160,9 +160,7 @@ namespace AyCode.Blazor.Components.Services
Logger.Error(errorText); Logger.Error(errorText);
//TODO: Ideiglenes, majd a ResponseMessage-et kell visszaadni a Status miatt! - J. //TODO: Ideiglenes, majd a ResponseMessage-et kell visszaadni a Status miatt! - J.
return await Task.FromException<TResponse>(new Exception(errorText)); throw new Exception(errorText);
//throw new Exception(errorText);
//return default; //return default;
} }