Solving the new version of btcpayserver caused btcpay-python not to create an order problem (#327)

This commit is contained in:
GameXG 2018-10-11 22:50:28 +08:00 committed by Nicolas Dorier
parent 60707fdbd1
commit db40c7bc32
2 changed files with 5 additions and 5 deletions

View file

@ -83,14 +83,14 @@ namespace BTCPayServer.Hosting
var path = httpContext.Request.Path.Value;
if (
bitpayAuth &&
path == "/invoices" &&
(path == "/invoices" || path == "/invoices/") &&
httpContext.Request.Method == "POST" &&
isJson)
return true;
if (
bitpayAuth &&
path == "/invoices" &&
(path == "/invoices" || path == "/invoices/") &&
httpContext.Request.Method == "GET")
return true;
@ -106,7 +106,7 @@ namespace BTCPayServer.Hosting
if (
path.Equals("/tokens", StringComparison.Ordinal) &&
( httpContext.Request.Method == "GET" || httpContext.Request.Method == "POST"))
(httpContext.Request.Method == "GET" || httpContext.Request.Method == "POST"))
return true;
return false;

View file

@ -210,14 +210,14 @@ namespace BTCPayServer.Security
var path = httpContext.Request.Path.Value;
if (
bitpayAuth &&
path == "/invoices" &&
(path == "/invoices" || path == "/invoices/") &&
httpContext.Request.Method == "POST" &&
isJson)
return true;
if (
bitpayAuth &&
path == "/invoices" &&
(path == "/invoices" || path == "/invoices/") &&
httpContext.Request.Method == "GET")
return true;