fixed crypto object created before directories are generated

master
Kevin Froman 2018-02-22 00:02:29 -06:00
parent 38bfee5344
commit 882f2e7020
No known key found for this signature in database
GPG Key ID: 0D414D0FE405B63B
1 changed files with 4 additions and 4 deletions

View File

@ -41,10 +41,6 @@ class Core:
self.blockDB = 'data/blocks.db'
self.blockDataLocation = 'data/blocks/'
self.addressDB = 'data/address.db'
self._utils = onionrutils.OnionrUtils(self)
# Initialize the crypto object
self._crypto = onionrcrypto.OnionrCrypto(self)
if not os.path.exists('data/'):
os.mkdir('data/')
@ -53,6 +49,10 @@ class Core:
if not os.path.exists(self.blockDB):
self.createBlockDB()
self._utils = onionrutils.OnionrUtils(self)
# Initialize the crypto object
self._crypto = onionrcrypto.OnionrCrypto(self)
return
def addPeer(self, peerID, name=''):