mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
add linkedParent in groupMetadata (#734)
* Update GroupMetadata.ts * Update groups.ts
This commit is contained in:
committed by
GitHub
parent
495bb6775a
commit
e52570bbd7
@@ -335,6 +335,7 @@ export const extractGroupMetadata = (result: BinaryNode) => {
|
|||||||
owner: group.attrs.creator ? jidNormalizedUser(group.attrs.creator) : undefined,
|
owner: group.attrs.creator ? jidNormalizedUser(group.attrs.creator) : undefined,
|
||||||
desc,
|
desc,
|
||||||
descId,
|
descId,
|
||||||
|
linkedParent: getBinaryNodeChild(group, 'linked_parent')?.attrs.jid || undefined,
|
||||||
restrict: !!getBinaryNodeChild(group, 'locked'),
|
restrict: !!getBinaryNodeChild(group, 'locked'),
|
||||||
announce: !!getBinaryNodeChild(group, 'announcement'),
|
announce: !!getBinaryNodeChild(group, 'announcement'),
|
||||||
isCommunity: !!getBinaryNodeChild(group, 'parent'),
|
isCommunity: !!getBinaryNodeChild(group, 'parent'),
|
||||||
|
|||||||
@@ -16,6 +16,8 @@ export interface GroupMetadata {
|
|||||||
desc?: string
|
desc?: string
|
||||||
descOwner?: string
|
descOwner?: string
|
||||||
descId?: string
|
descId?: string
|
||||||
|
/** if this group is part of a community, it returns the jid of the community to which it belongs */
|
||||||
|
linkedParent?: string
|
||||||
/** is set when the group only allows admins to change group settings */
|
/** is set when the group only allows admins to change group settings */
|
||||||
restrict?: boolean
|
restrict?: boolean
|
||||||
/** is set when the group only allows admins to write messages */
|
/** is set when the group only allows admins to write messages */
|
||||||
|
|||||||
Reference in New Issue
Block a user