Skip to content

Commit

Permalink
Fix closing app when node is closed already (#450)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilya Vilensky authored Mar 22, 2020
1 parent 14e06ea commit 09e0832
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion desktop/nodeManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const DEFAULT_PORT = '7153';
class NodeManager {
static startNode = async () => {
try {
const rawData = await fetch('http://ae7809a90692211ea8d4d0ea80dce922-597797094.us-east-1.elb.amazonaws.com/'); // http://nodes.unruly.io/
const rawData = await fetch('http://ae7809a90692211ea8d4d0ea80dce922-597797094.us-east-1.elb.amazonaws.com/');
const tomlData = await rawData.text();
const parsedToml = toml.parse(tomlData);

Expand Down Expand Up @@ -124,6 +124,8 @@ class NodeManager {
}
await stopNodeCycle(0);
});
} else {
await closeApp();
}
} catch (err) {
// could not find or kill node process
Expand Down

0 comments on commit 09e0832

Please sign in to comment.