Merge branch 'mkirk/fix-local-compare'

This commit is contained in:
Michael Kirk 2019-06-26 17:44:53 -06:00
commit 03349ca2cd

View File

@ -60,7 +60,16 @@ public class SignalServiceAddress: NSObject {
return false
}
return otherAddress.uuid == uuid || otherAddress.phoneNumber == phoneNumber
if let otherUuid = otherAddress.uuid, let thisUuid = uuid {
return otherUuid == thisUuid
}
if let otherPhone = otherAddress.phoneNumber, let thisPhone = phoneNumber {
return otherPhone == thisPhone
}
owsFailDebug("otherAddress had neither uuid nor phone")
return false
}
@objc