From 8df6e36c5338adefeb92472aa267f60a95e0366a Mon Sep 17 00:00:00 2001 From: matograine <matograine@zaclys.net> Date: Wed, 27 Oct 2021 16:56:12 +0200 Subject: [PATCH] [enh] #413 create function get_currency --- silkaj/blockchain_tools.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/silkaj/blockchain_tools.py b/silkaj/blockchain_tools.py index 53ce4de9..006496cc 100644 --- a/silkaj/blockchain_tools.py +++ b/silkaj/blockchain_tools.py @@ -48,3 +48,10 @@ class HeadBlock: def get_head(self): client = ClientInstance().client return client(blockchain.current) + + +def get_currency(): + client = ClientInstance().client + head_block = HeadBlock().head_block + currency = head_block["currency"] + return currency -- GitLab