Skip to content

Commit

Permalink
Fixing DeleteProductById method from ProductRepository
Browse files Browse the repository at this point in the history
  • Loading branch information
cristofima committed Nov 12, 2021
1 parent d5586b9 commit 82d2b70
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,10 @@ public void DeleteProductById(int productId)
this.storeContext.Products.Remove(product);
this.storeContext.SaveChanges();
}

throw new NotFoundException();
else
{
throw new NotFoundException();
}
}

public ProductResponse GetProductById(int productId)
Expand Down

0 comments on commit 82d2b70

Please sign in to comment.