i'm adding the Facebook module to my app in order to use the login Facebook button using appcelerator/titanium and alloy framework.
here is my code:
var fb = require('facebook');
fb.addEventListener('login',function(e){
if(e.success){
alert("connected");
}else{
alert("failure");
}
});
fb.addEventListener('logout',function(e){
if(e.success) {
alert("successfully logged out");
}else{
alert("failure");
}
});
var mybtn = fb.createLoginButton({
'top':'160',
'height':'35',
'width':'80%'
});
$.login_form.add(mybtn);
It seems that this part of this code causes the problem:
var mybtn = fb.createLoginButton({
'top':'160',
'height':'35',
'width':'80%'
});
$.login_form.add(mybtn);
The error is the following :
exception on thread: main msg:java.lang.RuntimeException: Unable to start activity ComponentInfo{com.copark.mobile/org.appcelerator.titanium.TiActivity}: Unexpected CallbackManager, please use the provided Factory.; Titanium 5.5.1,2016/09/27 05:39,b18727f
I don't really understand that error, and neither how to fix it. If anyone of you has the answer... :)
Thanks in advance,
Quentin