diff --git a/blessed/src/main/java/com/welie/blessed/BluetoothCentralManager.kt b/blessed/src/main/java/com/welie/blessed/BluetoothCentralManager.kt index 53e83a8..8eb58fe 100644 --- a/blessed/src/main/java/com/welie/blessed/BluetoothCentralManager.kt +++ b/blessed/src/main/java/com/welie/blessed/BluetoothCentralManager.kt @@ -778,9 +778,8 @@ class BluetoothCentralManager(private val context: Context) { // Try to remove the bond return if (peripheralToUnBond != null) { try { - // TODO FIX THIS, automatic conversion gone wrong - val method = peripheralToUnBond.javaClass.getMethod("removeBond", null) - val result = method.invoke(peripheralToUnBond, null as Array?) as Boolean + val method = peripheralToUnBond.javaClass.getMethod("removeBond") + val result = method.invoke(peripheralToUnBond) as Boolean if (result) { Logger.i(TAG, "Succesfully removed bond for '%s'", peripheralToUnBond.name) }