mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-17 14:04:26 +01:00
Fix: Creating a new invoice in payment request with LNURL activated would crash
This commit is contained in:
@@ -215,7 +215,7 @@ namespace BTCPayServer.Controllers.GreenField
|
||||
try
|
||||
{
|
||||
var invoice = await _invoiceController.CreateInvoiceCoreRaw(request, store,
|
||||
Request.GetAbsoluteUri(""));
|
||||
Request.GetAbsoluteRoot());
|
||||
return Ok(ToModel(invoice));
|
||||
}
|
||||
catch (BitpayHttpException e)
|
||||
|
||||
@@ -275,7 +275,7 @@ namespace BTCPayServer.Controllers
|
||||
};
|
||||
|
||||
var additionalTags = new List<string> {PaymentRequestRepository.GetInternalTag(id)};
|
||||
var newInvoice = await _InvoiceController.CreateInvoiceCoreRaw(invoiceRequest,store, "/",additionalTags, cancellationToken);
|
||||
var newInvoice = await _InvoiceController.CreateInvoiceCoreRaw(invoiceRequest,store, Request.GetAbsoluteRoot(), additionalTags, cancellationToken);
|
||||
|
||||
if (redirectToInvoice)
|
||||
{
|
||||
|
||||
@@ -193,7 +193,7 @@ namespace BTCPayServer.Plugins.Shopify
|
||||
Currency = order.Currency,
|
||||
Metadata = new JObject {["orderId"] = invoiceOrderId}
|
||||
}, store,
|
||||
Request.GetAbsoluteUri(""), new List<string>() {invoiceOrderId});
|
||||
Request.GetAbsoluteRoot(), new List<string>() {invoiceOrderId});
|
||||
|
||||
return Ok(new {invoiceId = invoice.Id, status = invoice.Status.ToString().ToLowerInvariant()});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user