We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 4bb81b9 + b2c51b4 commit 525daffCopy full SHA for 525daff
src/whatsapp/services/whatsapp.service.ts
@@ -1734,6 +1734,7 @@ export class WAStartupService {
1734
{
1735
messages,
1736
chats,
1737
+ contacts,
1738
}: {
1739
chats: Chat[];
1740
contacts: Contact[];
@@ -1846,6 +1847,17 @@ export class WAStartupService {
1846
1847
);
1848
}
1849
1850
+ await this.contactHandle['contacts.upsert'](
1851
+ contacts
1852
+ .filter((c) => !!c.notify ?? !!c.name)
1853
+ .map((c) => ({
1854
+ id: c.id,
1855
+ name: c.name ?? c.notify,
1856
+ })),
1857
+ database,
1858
+ );
1859
+
1860
+ contacts = undefined;
1861
messages = undefined;
1862
chats = undefined;
1863
} catch (error) {
0 commit comments