Fix contact sync for aci-less contacts

This commit is contained in:
Fedor Indutny
2025-07-09 09:14:25 -07:00
committed by GitHub
parent 6ec9dd60b1
commit 3063262730
2 changed files with 2 additions and 30 deletions

View File

@@ -13,6 +13,7 @@ import type { AciString } from '../types/ServiceId';
import { computeHash } from '../Crypto';
import { dropNull } from '../util/dropNull';
import { fromAciUuidBytesOrString } from '../util/ServiceId';
import * as Bytes from '../Bytes';
import { decryptAttachmentV2ToSink } from '../AttachmentCrypto';
import Avatar = Proto.ContactDetails.IAvatar;
@@ -204,7 +205,7 @@ function prepareContact(
const aci = fromAciUuidBytesOrString(aciBinary, rawAci, 'ContactBuffer.aci');
if (aci == null) {
if ((Bytes.isNotEmpty(aciBinary) || rawAci) && aci == null) {
log.warn('ParseContactsTransform: Dropping contact with invalid aci');
return undefined;
}