I have a Nativescript App built with Angular and I use the Nativescript Plugin Firebase: https://github.com/EddyVerbruggen/nativescript-plugin-firebase.
When I authenticate with Facebook, it retrieves me the user data successfully, but the user does not appear as logged in, and the onAuthStateChanged() listener is not triggered.
The function I use is the simplest one:
public async signInWithFacebookPopup(): Promise<any> {
return await firebase.login({
type: firebase.LoginType.FACEBOOK
}).then(
function (result) {
return result;
},
function (errorMessage) {
return {error: errorMessage};
}
);
}
So here the "result" I get is the actual user data.
Shouldn't the method onAuthStateChanged() be triggered? Also, after logging in and getting the user's data, If I call firebaseWeb.auth().currentUser, I get undefined.
[UPDATE]
When the Facebook window is displayed (before introducing my credentials), I get this error in the console:
chromium: [INFO:library_loader_hooks.cc(51)] Chromium logging enabled: level = 0, default verbosity = 0
chromium: [ERROR:filesystem_posix.cc(89)] stat /data/user/0/[APP_NAME]/cache/WebView/Crashpad: No such file or directory (2)
chromium: [ERROR:filesystem_posix.cc(62)] mkdir /data/user/0/[APP_NAME]/cache/WebView/Crashpad: No such file or directory (2)
Could it be that this one breaks some other behaviours later?