From 4690113fb237fd328d95545c16a8a2d5a6a6dfc1 Mon Sep 17 00:00:00 2001 From: supertestnet <58400631+supertestnet@users.noreply.github.com> Date: Thu, 16 Mar 2023 15:17:13 -0500 Subject: [PATCH] Update testnet.html --- testnet.html | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/testnet.html b/testnet.html index 81566ea..3a2320e 100644 --- a/testnet.html +++ b/testnet.html @@ -422,6 +422,15 @@ fees = JSON.parse( fees ); return fees; } + function isValidJson( content ) { + if ( !content ) return; + try { + var json = JSON.parse( content ); + } catch ( e ) { + return; + } + return true; + } function getData( url ) { return new Promise( async function( resolve, reject ) { function inner_get( url ) {