Skip to content

Commit

Permalink
Added block difficulty to stat endpoint (#404)
Browse files Browse the repository at this point in the history
* Added block difficulty to stat endpoint

* Improved code

* Applied changes from code review

* Fixed tests failur]

* Updated code per code review

* Improved code based on code review
  • Loading branch information
siradji authored Sep 28, 2021
1 parent 83c1fd9 commit f5b5355
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions apps/whale-api/src/module.api/stats.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ export class StatsController {
price: await this.cachedGet('price', this.getPrice.bind(this), 300),
masternodes: {
locked: masternodes.locked
},
blockchain: {
difficulty: block?.difficulty ?? 0
}
}
}
Expand Down

0 comments on commit f5b5355

Please sign in to comment.