File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change 11from src .transaction .transaction import Transaction
22from src .proto import token_create_pb2
33from src .response_code import ResponseCode
4+ from src .proto import basic_types_pb2
45
56class TokenCreateTransaction (Transaction ):
67 """
@@ -76,13 +77,17 @@ def build_transaction_body(self):
7677 ]):
7778 raise ValueError ("Missing required fields" )
7879
80+ key = basic_types_pb2 .Key (
81+ ed25519 = self .admin_key .to_string () if self .admin_key else None
82+ )
83+
7984 token_create_body = token_create_pb2 .TokenCreateTransactionBody (
8085 name = self .token_name ,
8186 symbol = self .token_symbol ,
8287 decimals = self .decimals ,
8388 initialSupply = self .initial_supply ,
8489 treasury = self .treasury_account_id .to_proto (),
85- adminKey = self . admin_key . to_proto () if self .admin_key else None
90+ adminKey = key if self .admin_key else None
8691 )
8792
8893 transaction_body = self .build_base_transaction_body ()
You can’t perform that action at this time.
0 commit comments