fix: properly send inbandregistration requests
This commit is contained in:
parent
4e4a290813
commit
b99b412692
3 changed files with 117 additions and 114 deletions
|
@ -396,7 +396,10 @@ func (m *UserManager) cleanupGhostUser(mattermostUserID string) error {
|
|||
}
|
||||
|
||||
// Unregister the ghost user account via XEP-0077
|
||||
response, err := regHandler.CancelRegistration(ghostJIDParsed.Domain())
|
||||
cancellationRequest := &xmppClient.CancellationRequest{
|
||||
Username: ghostJIDParsed.Localpart(), // Extract username from ghost JID
|
||||
}
|
||||
response, err := regHandler.CancelRegistration(ghostJIDParsed.Domain(), cancellationRequest)
|
||||
if err != nil {
|
||||
return fmt.Errorf("failed to cancel registration for ghost user %s: %w", ghostData.GhostJID, err)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue