registerOnRemoveHandler - called but after removal there is an option to cancel it.(teams connector)

Occasional Contributor

When removing an msteams connector resgistered using registerOnRemoveHandler, 

the onremove event is called, but later there is an option to cancel the removal.

But this is to late as the data we store regarding to the specific connector is already removed.


I think this is a bug.


A correct behaviour would be to call the remove just on the final step on the second dialog.


What do you think?

1 Reply
best response confirmed by someone_developing (Occasional Contributor)

Currently, microsoftTeams.settings.registerOnRemoveHandler() is called whenever remove button is clicked. This is where you can do the clean up operation.


Know issue - User could possibly cancel the removal flow on feedback screen and there is no way to know that. We are working on the fix.


Currently, the workaround is to use Webhook 410 Gone response as the trigger to perform cleanup operations until the issue is fixed.
This known issue has been fixed. We no longer show feedback screen when user clicks on Remove for Connector. You can perform your cleanup operations on registerOnRemoveHandler()event and be sure that Connector has been removed.