RxAndroidBle icon indicating copy to clipboard operation
RxAndroidBle copied to clipboard

RxBleAdapterStateObservable emits values when BLE is not supported

Open dariuszseweryn opened this issue 6 years ago • 0 comments

Summary

As in the topic

Library version

1.5.0 Rx1/Rx2

Preconditions

A phone that does not have BLE capabilities

Steps to reproduce actual result


1. Subscribe to RxBleAdapterStateObservable
2. Change Bluetooth Adapter State
3. Observe emissions

Minimum code snippet reproducing the issue

new RxBleAdapterStateObservable(context)
  .subscribe(state -> Log.e("NEW ADAPTER STATE", state.toString());

Actual result

Emissions of the BluetoothAdapter state

Expected result

A single emission of STATE_UNSUPPORTED (naming to be discussed)

dariuszseweryn avatar Mar 16 '18 11:03 dariuszseweryn