From a500a891387d6328f153e2053db5a7c8a4fde462 Mon Sep 17 00:00:00 2001 From: "nicolas.dorier" Date: Thu, 29 Mar 2018 12:09:57 +0900 Subject: [PATCH] Revert "add hack sqlite specific" This reverts commit c6d44e7a8936fe9ac7bb85f221ed176afd8b8540. --- BTCPayServer/Services/Invoices/InvoiceRepository.cs | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/BTCPayServer/Services/Invoices/InvoiceRepository.cs b/BTCPayServer/Services/Invoices/InvoiceRepository.cs index 25c91526d..43acf5305 100644 --- a/BTCPayServer/Services/Invoices/InvoiceRepository.cs +++ b/BTCPayServer/Services/Invoices/InvoiceRepository.cs @@ -52,8 +52,7 @@ namespace BTCPayServer.Services.Invoices ctx.PendingInvoices.Remove(new PendingInvoiceData() { Id = invoiceId }); try { - if (await ctx.SaveChangesAsync() == 0) - return false; + await ctx.SaveChangesAsync(); return true; } catch (DbUpdateException) { return false; } @@ -509,13 +508,6 @@ namespace BTCPayServer.Services.Invoices try { - if (context.Database.ProviderName == "Microsoft.EntityFrameworkCore.Sqlite") - { - if (await context.Payments.AnyAsync(p => p.Id == paymentData.GetPaymentId())) - { - return null; - } - } if (await context.SaveChangesAsync().ConfigureAwait(false) == 0) return null; }