Merge "Support comparison of byte array values in areBundlesEqual" into tm-dev am: 548c0800c2 am: 70b9ba370c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18357438 Change-Id: I55fc4553de24b15aae886aec11173d7685026fcb Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -2895,7 +2895,19 @@ public final class Call {
|
||||
if (key != null) {
|
||||
final Object value = bundle.get(key);
|
||||
final Object newValue = newBundle.get(key);
|
||||
if (!Objects.equals(value, newValue)) {
|
||||
if (!newBundle.containsKey(key)) {
|
||||
return false;
|
||||
}
|
||||
if (value instanceof Bundle && newValue instanceof Bundle) {
|
||||
if (!areBundlesEqual((Bundle) value, (Bundle) newValue)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if (value instanceof byte[] && newValue instanceof byte[]) {
|
||||
if (!Arrays.equals((byte[]) value, (byte[]) newValue)) {
|
||||
return false;
|
||||
}
|
||||
} else if (!Objects.equals(value, newValue)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user