aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--java/BluetoothObject.java8
1 files changed, 3 insertions, 5 deletions
diff --git a/java/BluetoothObject.java b/java/BluetoothObject.java
index d1ab0c76..7b1ecb79 100644
--- a/java/BluetoothObject.java
+++ b/java/BluetoothObject.java
@@ -64,12 +64,10 @@ public class BluetoothObject implements Cloneable
delete();
}
- public boolean equals(BluetoothObject obj)
+ public boolean equals(Object obj)
{
- if (obj == null)
- {
+ if (obj == null || !(obj instanceof BluetoothObject))
return false;
- }
- return operatorEqual(obj);
+ return operatorEqual((BluetoothObject)obj);
}
}