1

I have a webview in my bot. I have the following JS code to close it:

complete: function (data) {
                    MessengerExtensions.requestCloseBrowser(function success() {
                        }, function error(err) {
                            window.close()
                        });
                    console.log("post success");
                }

The webview is being closed on ANDROID and WEB But NOT on IOS.

Any help would be appreciated.

OmriToptix
  • 1,219
  • 1
  • 15
  • 22

2 Answers2

3

So apparently my problem was a mistake which led to a misunderstanding of the problem.

I didn't add messenger_extensions: true and didn't whitelist my domain. Due to that the MessengerExtensions call failed, and always got to the fallback which was window.close() - which works on WEB and Android, but not on IOS - hence I thought that all works but IOS.

After adding messenger_extensions: true and whitelisting the domain all worked out.

OmriToptix
  • 1,219
  • 1
  • 15
  • 22
1

You can search for related bugs here, i searched for a one related to your issue but there is none.

akinmail
  • 638
  • 6
  • 14