diff --git a/tonsdk_ng/boc/_bit_string.py b/tonsdk_ng/boc/_bit_string.py index 5a9967b..b21ff8d 100644 --- a/tonsdk_ng/boc/_bit_string.py +++ b/tonsdk_ng/boc/_bit_string.py @@ -97,7 +97,7 @@ def get_free_bits(self) -> int: def get_used_bits(self): return self.cursor - def write_bit_array(self, ba: bytearray): + def write_bit_array(self, ba: bytearray | bytes): """Writes a bytearray as a bit array one bit by one.""" for b in ba.decode("utf-8"): self.write_bit(b) diff --git a/tonsdk_ng/contract/wallet/_highload_wallet_contract.py b/tonsdk_ng/contract/wallet/_highload_wallet_contract.py index de89ac2..e1132aa 100644 --- a/tonsdk_ng/contract/wallet/_highload_wallet_contract.py +++ b/tonsdk_ng/contract/wallet/_highload_wallet_contract.py @@ -39,8 +39,8 @@ def create_transfer_message( timeout=60, dummy_signature=False, ): - if query_id < int(time.time() + timeout) << 32: - query_id = int(time.time() + timeout) << 32 + query_id + if query_id < (t := int(time.time() + timeout) << 32): + query_id = t + query_id signing_message = self.create_signing_message(query_id) recipients = begin_dict(16)