Skip to content

Commit

Permalink
Removed unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
pkirilin committed Mar 9, 2024
1 parent e66a280 commit 20811f5
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 15 deletions.
Original file line number Diff line number Diff line change
@@ -1,16 +1,10 @@
using System.Threading;
using System.Threading.Tasks;
using FoodDiary.Domain.Repositories.v2;

namespace FoodDiary.Domain.Abstractions.v2;

public interface IFoodDiaryUnitOfWork
{
IPagesRepository Pages { get; }

IProductsRepository Products { get; }

ICategoriesRepository Categories { get; }

Task SaveChangesAsync(CancellationToken cancellationToken);
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
using System.Threading;
using System.Threading.Tasks;
using FoodDiary.Domain.Abstractions.v2;
using FoodDiary.Domain.Repositories.v2;
using FoodDiary.Infrastructure.Repositories.v2;
Expand All @@ -14,15 +12,8 @@ public FoodDiaryUnitOfWork(FoodDiaryContext context)
{
_context = context;
}

public IPagesRepository Pages => new PagesRepository(_context);

public IProductsRepository Products => new ProductsRepository(_context.Products);

public ICategoriesRepository Categories => new CategoriesRepository(_context.Categories);

public async Task SaveChangesAsync(CancellationToken cancellationToken)
{
await _context.SaveChangesAsync(cancellationToken);
}
}

0 comments on commit 20811f5

Please sign in to comment.