From b58331ec65dc3ce98a42a90e8de6158de2e33177 Mon Sep 17 00:00:00 2001 From: Heri Sim <527101+heri16@users.noreply.github.com> Date: Fri, 29 Sep 2023 14:00:39 +0800 Subject: [PATCH] Fix Compat Breez Wallet (#5) --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index e94412f..4f25a18 100644 --- a/index.js +++ b/index.js @@ -1706,7 +1706,7 @@ const requestListener = async function( request, response ) { } else { var min = Math.floor( ( 546 + ( ( feerate * 200 ) * 2 ) ) / ( 1 - ( fee / 100 ) ) ); } - if ( !$_GET || !$_GET[ "amount" ] || isNaN( $_GET[ "amount" ] ) || !parts.path.includes( "?amount=" ) || Math.round( Number( $_GET[ "amount" ] ) / 1000 ) < min ) { + if ( !$_GET || !$_GET[ "amount" ] || isNaN( $_GET[ "amount" ] ) || Math.round( Number( $_GET[ "amount" ] ) / 1000 ) < min ) { sendResponse( response, JSON.stringify( json ), 200, {'Content-Type': 'application/json'} ); return; }