From a9b4331f12a1f9ddb9051a9fc3058c1474d5ca44 Mon Sep 17 00:00:00 2001 From: jahway603 Date: Thu, 21 Oct 2021 01:25:14 -0400 Subject: [PATCH] minor --- getstats | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/getstats b/getstats index 68d6832..b119f4d 100644 --- a/getstats +++ b/getstats @@ -11,11 +11,10 @@ use strict; use warnings; use Data::Dumper; use JSON; -#use Getopt::Long; use Getopt::Long; -my $node_client = 'hush-cli'; # hush-cli client -my $block_height = 699000; # start block unless changed with --block +my $node_client = 'hush-cli'; # hush-cli client +my $block_height = 699000; # start block unless changed with --block my $version = "0.1"; my $print_version; @@ -58,7 +57,7 @@ sub read_json { my ($raw) = @_; - eval { decode_json($raw) }; # eval first, bad JSON kills puppies + eval { decode_json($raw) }; # eval first, bad JSON kills puppies if (!$@) { return(decode_json($raw)); @@ -76,7 +75,7 @@ sub node_cli { my $response = qx{$node_client $command 2>/dev/null}; - my $json = read_json($response); # bad JSON kills puppies too + my $json = read_json($response); if ($json) { return($json);