The code expects to be called form UI thread, but it loks like JavaScript
callbacks are not. Switch to UI thread when invoking a callback.
Signed-off-by: Oldřich Jedlička <oldium.pro@gmail.com>
In the callback the processing does not go in the main UI thread, so we
need to switch there. Otherwise on Android this throws
Android.Util.AndroidRuntimeException with detail “Only the original thread
that created a view hierarchy can touch its views”.
Discovered by trying to login with Duo as a two-factor login type.
Signed-off-by: Oldřich Jedlička <oldium.pro@gmail.com>