mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
minor cleanup
This commit is contained in:
parent
3c2357b5db
commit
b91f348a3f
2 changed files with 2 additions and 7 deletions
|
|
@ -2,11 +2,9 @@
|
|||
using FilterLists.Data.Models;
|
||||
using FilterLists.Data.Repositories.Contracts;
|
||||
using FilterLists.Services.Contracts;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
namespace FilterLists.Services.Implementations
|
||||
{
|
||||
[UsedImplicitly]
|
||||
public class ListService : IListService
|
||||
{
|
||||
private readonly IListRepository _listRepository;
|
||||
|
|
|
|||
|
|
@ -8,12 +8,10 @@ namespace FilterLists.Services.Implementations
|
|||
{
|
||||
public class TableService : ITableService
|
||||
{
|
||||
private readonly IListRepository _listRepository;
|
||||
private readonly ITableCsvRepository _tableCsvRepository;
|
||||
|
||||
public TableService(IListRepository listRepository, ITableCsvRepository tableCsvRepository)
|
||||
public TableService(ITableCsvRepository tableCsvRepository)
|
||||
{
|
||||
_listRepository = listRepository;
|
||||
_tableCsvRepository = tableCsvRepository;
|
||||
}
|
||||
|
||||
|
|
@ -49,8 +47,7 @@ private static async Task<string> FetchFile(string url, string fileName)
|
|||
var path = Path.Combine(Directory.GetCurrentDirectory(), "csv");
|
||||
Directory.CreateDirectory(path);
|
||||
var file = Path.Combine(path, fileName + ".csv");
|
||||
using (var fileStream = new FileStream(file, FileMode.Create, FileAccess.Write,
|
||||
FileShare.None))
|
||||
using (var fileStream = new FileStream(file, FileMode.Create, FileAccess.Write, FileShare.None))
|
||||
{
|
||||
await response.Content.CopyToAsync(fileStream);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue