Log when DEBUG is on

Bug: 181588752
Test: manual

Change-Id: I43331ad011c9667d05ca752f523bc65883977c3c
This commit is contained in:
Hansong Zhang
2021-08-17 12:26:57 -07:00
parent 36a42b630b
commit 13f41075d4

View File

@@ -103,8 +103,10 @@ public class AdvancedBluetoothDetailsHeaderController extends BasePreferenceCont
new BluetoothAdapter.OnMetadataChangedListener() {
@Override
public void onMetadataChanged(BluetoothDevice device, int key, byte[] value) {
Log.i(TAG, String.format("Metadata updated in Device %s: %d = %s.", device, key,
value == null ? null : new String(value)));
if (DEBUG) {
Log.d(TAG, String.format("Metadata updated in Device %s: %d = %s.", device,
key, value == null ? null : new String(value)));
}
refresh();
}
};