| 359 | } |
| 360 | |
| 361 | static UniValue getdifficulty(const JSONRPCRequest& request) |
| 362 | { |
| 363 | if (request.fHelp || request.params.size() != 0) |
| 364 | throw std::runtime_error( |
| 365 | "getdifficulty\n" |
| 366 | "\nReturns the proof-of-work difficulty as a multiple of the minimum difficulty.\n" |
| 367 | "\nResult:\n" |
| 368 | "n.nnn (numeric) the proof-of-work difficulty as a multiple of the minimum difficulty.\n" |
| 369 | "\nExamples:\n" |
| 370 | + HelpExampleCli("getdifficulty", "") |
| 371 | + HelpExampleRpc("getdifficulty", "") |
| 372 | ); |
| 373 | |
| 374 | LOCK(cs_main); |
| 375 | return GetDifficulty(chainActive.Tip()); |
| 376 | } |
| 377 | |
| 378 | static std::string EntryDescriptionString() |
| 379 | { |
nothing calls this directly
no test coverage detected