Change memo message encoding for python3

This commit is contained in:
Ben Wilson 2019-10-21 12:17:32 -04:00
parent 7085129b84
commit d9b542b723
1 changed files with 2 additions and 1 deletions

View File

@ -1,5 +1,6 @@
import requests
import json
import binascii
from pyZcash.settings import *
@ -136,7 +137,7 @@ class ZDaemon(object):
if memo == '':
amounts = {"address": receiver, "amount": amount}
else:
memo = memo.encode('hex')
memo = binascii.hexlify(str.encode(memo))
amounts = {"address": receiver, "amount": amount, "memo": memo}
amts_array.append(amounts)
return self._call('z_sendmany', sender, amts_array, 1, fee)