Display network hashrate in public API

Instead of 0 show the actual hashrate, still shows 0 if unable to
connect to RPC server.

Fixes #511
Merge pull request #519 from TheSerapher/issue-511

Display network hashrate in public API