We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9a7e8f2 commit 7e360f6Copy full SHA for 7e360f6
src/ui/menubar/menubar.js
@@ -320,7 +320,15 @@ cwc.ui.Menubar.prototype.closeWindow = function() {
320
this.log_.info('Close Coding with Chrome editor ...');
321
let bluetoothInstance = this.helper.getInstance('bluetooth');
322
if (bluetoothInstance) {
323
- bluetoothInstance.closeSockets();
+ let featuresInstance = this.helper.getInstance('features');
324
+ if (featuresInstance) {
325
+ if (featuresInstance.getChromeFeature('bluetoothSocket')) {
326
+ bluetoothInstance.closeSockets();
327
+ }
328
+ } else {
329
+ this.log_.warn('Failed to get Features helper.'+
330
+ 'Can\'t check if bluetoothSocket is supported');
331
332
}
333
this.currentWindow['close']();
334
};
0 commit comments