Skip to content
Snippets Groups Projects
Verified Commit 0c7c465e authored by akwizgran's avatar akwizgran
Browse files

Remove unnecessary executor calls.

parent fd6bf42e
No related branches found
No related tags found
No related merge requests found
......@@ -186,13 +186,8 @@ class AndroidBluetoothPlugin extends BluetoothPlugin<BluetoothServerSocket> {
@Override
public void onReceive(Context ctx, Intent intent) {
int state = intent.getIntExtra(EXTRA_STATE, 0);
if (state == STATE_ON) {
ioExecutor.execute(
AndroidBluetoothPlugin.this::onAdapterEnabled);
} else if (state == STATE_OFF) {
ioExecutor.execute(
AndroidBluetoothPlugin.this::onAdapterDisabled);
}
if (state == STATE_ON) onAdapterEnabled();
else if (state == STATE_OFF) onAdapterDisabled();
int scanMode = intent.getIntExtra(EXTRA_SCAN_MODE, 0);
if (scanMode == SCAN_MODE_NONE) {
LOG.info("Scan mode: None");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment