Fix an infinite loop that could happen when trying to bootstrap if the key exchange fails

Change-Type: patch
This commit is contained in:
Pagan Gazzard 2017-04-26 13:54:15 -07:00
parent 89ccb6480d
commit 42cd3a6b01

View File

@ -156,6 +156,7 @@ bootstrapper.done = new Promise (resolve) ->
knex('config').update(value: userConfig.deviceApiKey).where(key: 'apiKey') knex('config').update(value: userConfig.deviceApiKey).where(key: 'apiKey')
.then -> .then ->
fs.writeFileAsync(configPath, JSON.stringify(userConfig)) fs.writeFileAsync(configPath, JSON.stringify(userConfig))
return
bootstrapper.bootstrapped = false bootstrapper.bootstrapped = false