diff options
author | Bartosz Jaroszewski <b.jarosze@gmail.com> | 2022-04-11 15:01:20 +0200 |
---|---|---|
committer | Bartosz Jaroszewski <b.jarosze@gmail.com> | 2022-04-11 15:01:20 +0200 |
commit | 20e6eccb63abb4c97bef5d0e0a7d78842aa72da7 (patch) | |
tree | 3668c139d3d1f0851457c10307dd3a29f339e6ba | |
parent | 5a63d94585d025f2bdf8870b8d56ca83b79c73ae (diff) |
do not create object in global scope
-rw-r--r-- | extension.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/extension.js b/extension.js index 0b70bbe..b3c7167 100644 --- a/extension.js +++ b/extension.js @@ -21,8 +21,7 @@ const ExtensionUtils = imports.misc.extensionUtils; const Me = ExtensionUtils.getCurrentExtension(); const UiExtension = Me.imports.ui; -const GnomeBluetooth = imports.gi.GnomeBluetooth; -const Bluetooth = new GnomeBluetooth.Client().get_devices === undefined ? +const Bluetooth = imports.gi.GnomeBluetooth.Client.prototype.get_devices === undefined ? Me.imports.bluetooth_legacy : Me.imports.bluetooth; |