Skip to content

Commit 6a5f6aa

Browse files
author
Stefania
committed
minor improvements
1 parent efd9751 commit 6a5f6aa

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/daemon.js

-4
Original file line numberDiff line numberDiff line change
@@ -160,8 +160,4 @@ export default class Daemon {
160160
throw new Error('Stop Upload not supported on Chrome OS');
161161
}
162162
}
163-
164-
initUpload() {
165-
this.uploading.next({ status: this.UPLOAD_NOPE });
166-
}
167163
}

src/socket-daemon.js

+6-2
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ const LOOPBACK_HOST = `${PROTOCOL.HTTPS}://localhost`;
4343
const LOOKUP_PORT_START = 8991;
4444
const LOOKUP_PORT_END = 9000;
4545
let orderedPluginAddresses = [LOOPBACK_ADDRESS, LOOPBACK_HOST];
46+
let driversRequested = false;
4647

4748
const CANT_FIND_AGENT_MESSAGE = 'Arduino Create Agent cannot be found';
4849

@@ -179,8 +180,11 @@ export default class SocketDaemon extends Daemon {
179180

180181
this.socket.on('connect', () => {
181182
// On connect download windows drivers which are indispensable for detection of boards
182-
this.downloadTool('windows-drivers', 'latest', 'arduino');
183-
this.downloadTool('bossac', '1.7.0', 'arduino');
183+
if (!driversRequested) {
184+
this.downloadTool('windows-drivers', 'latest', 'arduino');
185+
this.downloadTool('bossac', '1.7.0', 'arduino');
186+
driversRequested = false;
187+
}
184188

185189
this.initSocket();
186190

0 commit comments

Comments
 (0)