Skip to content
This repository has been archived by the owner on May 15, 2024. It is now read-only.

Commit

Permalink
store + protocol version
Browse files Browse the repository at this point in the history
  • Loading branch information
BitDesert committed Jun 30, 2019
1 parent 42ff152 commit 831ee8f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion api.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,10 @@
$data->nanoNodeAccountUrl = getAccountUrl($data->nanoNodeAccount, $blockExplorer);

// -- Get Version String from nano node and node monitor
$data->version = getVersion($ch);
$version = getVersion($ch);
$data->version = $version->{'node_vendor'};
$data->store_version = (int) $version->{'store_version'} ?: 0;
$data->protocol_version = (int) $version->{'protocol_version'} ?: 0;

// Cache the github query for latest node version
global $nodeVersionCache;
Expand Down
2 changes: 1 addition & 1 deletion modules/functions_rpc.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ function getVersion($ch)
$data = array("action" => "version");

// post curl
return postCurl($ch, $data)->{'node_vendor'};
return postCurl($ch, $data);
}

// get block count from nano_node
Expand Down

0 comments on commit 831ee8f

Please sign in to comment.