Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion src/BleManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -566,7 +566,15 @@ export class BleManager {
const nativeDevice = await this._callPromise(
BleModule.discoverAllServicesAndCharacteristicsForDevice(deviceIdentifier, transactionId)
)
return new Device(nativeDevice, this)
const services = await this._callPromise(BleModule.servicesForDevice(deviceIdentifier))
const serviceUUIDs = services.map(service => service.uuid)

// $FlowFixMe
const device = {
...nativeDevice,
serviceUUIDs
}
return new Device(device, this)
}

// Mark: Service and characteristic getters --------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion src/BleModule.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export interface NativeDevice {
rawScanRecord: Base64;

/**
* Map od service UUIDs with associated data.
* Map of service UUIDs with associated data.
* @private
*/
serviceData: ?{ [uuid: UUID]: Base64 };
Expand Down
Loading