mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2026-01-06 07:34:26 +01:00
Fix form processing when cart is enabled (#424)
This commit is contained in:
committed by
Nicolas Dorier
parent
bab7bf6633
commit
613281a1e7
@@ -76,11 +76,7 @@ namespace BTCPayServer.Controllers
|
|||||||
if (app == null)
|
if (app == null)
|
||||||
return NotFound();
|
return NotFound();
|
||||||
var settings = app.GetSettings<PointOfSaleSettings>();
|
var settings = app.GetSettings<PointOfSaleSettings>();
|
||||||
if (string.IsNullOrEmpty(choiceKey) && !settings.EnableShoppingCart)
|
if (string.IsNullOrEmpty(choiceKey) && !settings.ShowCustomAmount && !settings.EnableShoppingCart)
|
||||||
{
|
|
||||||
return RedirectToAction(nameof(ViewPointOfSale), new { appId = appId });
|
|
||||||
}
|
|
||||||
if (string.IsNullOrEmpty(choiceKey) && !settings.ShowCustomAmount)
|
|
||||||
{
|
{
|
||||||
return RedirectToAction(nameof(ViewPointOfSale), new { appId = appId });
|
return RedirectToAction(nameof(ViewPointOfSale), new { appId = appId });
|
||||||
}
|
}
|
||||||
@@ -99,7 +95,7 @@ namespace BTCPayServer.Controllers
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (!settings.ShowCustomAmount)
|
if (!settings.ShowCustomAmount && !settings.EnableShoppingCart)
|
||||||
return NotFound();
|
return NotFound();
|
||||||
price = amount;
|
price = amount;
|
||||||
title = settings.Title;
|
title = settings.Title;
|
||||||
|
|||||||
Reference in New Issue
Block a user