Commit 3f4debfa authored by 曾思程's avatar 曾思程

isStopConnectionCheck为true时,停止触发连接事件。停止tryconecnt报错的异常抛出

parent a5e69e05
......@@ -109,7 +109,6 @@ function Jensen(log) {
self.model = device.productId == 45069 ? 'hidock-h1e' : 'hidock-h1';
} catch (e) {
Logger.error('jensen', 'setup', String(e));
throw e;
}
if (!disableOnConnect) _check_conn_status();
current = null;
......@@ -117,7 +116,7 @@ function Jensen(log) {
ready = true;
Logger.debug('jensen', 'setup', 'setup webusb connection');
try {
if (!disableOnConnect) self.onconnect?.();
if (!disableOnConnect && !this.isStopConnectionCheck) self.onconnect?.();
} catch (err) {
Logger.error('jensen', 'setup', err);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment