Skip to content

Commit

Permalink
ensure data is bytes
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaojay committed Apr 20, 2024
1 parent 733e57c commit 4441707
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arseeding/bundleitem.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ class BundleItem:
def __init__(self, signer, target, anchor, tags, data):
if type(tags) == type({}):
tags = [{'name':k, 'value':v} for k,v in tags.items()]
if type(data) != type(b''):
data = data.encode('utf-8')
self.signer = signer
self.signature_type = sig_conf[signer.type.lower()]['signature_type']

Expand Down

0 comments on commit 4441707

Please sign in to comment.