time, but sometimes I get this message in the log:
c:0:3: Primary connection is healthy.
p:0: from server: {"r":15,"b":{"s":"ok","d":{}}}
p:0: listen response {"s":"ok","d":{}}
p:0: from server: {"r":16,"b":{"s":"ok","d":""}}
p:0: p response {"s":"ok","d":""}
p:0: from server: {"r":17,"b":{"s":"ok","d":""}}
p:0: p response {"s":"ok","d":""}
p:0: from server: {"r":18,"b":{"s":"ok","d":""}}
p:0: m response {"s":"ok","d":""}
p:0: Browser went offline. Killing connection.
c:0:3: Closing realtime connection.
c:0:3: Shutting down all connections
c:0:3:0 Longpoll is being closed.
p:0: data client disconnected
0: onDisconnectEvents
And the request never terminates.
The app runs Angular 1.4, Ionic 1.1.0, AngularFire 1.1.3 and Firebase
2.2.9. The problem occurs on both Android and iPhone regardless of the
version.
My phone is on a good wifi to discard network related issues.
Here is the related JS code:
var facebookUid = '1213161789'; // result from the facebook native plugin
var ref = new Firebase(config.firebaseurl + '/users');
$firebaseObject(ref.child(facebookUid))
.$loaded()
.then(function(firebaseUser) {
.... // sometimes called
})
.catch(function(firebaseUser) {
.... // never called
})
;
I tried to force long poll instead of web sockets but with no visible
changes. The problem originally happened with the plain Firebase object,
and switching to AngularFire didn't solved it.
It appears that navigator.online is true and when we try to force the
connection with Firebase.goOnline() the connection is not restored...
This maybe not related but:
- According to the documentation, I also added the following to my
config.xml
- <allow-intent href="*.firebaseio.com" />
- <allow-intent href="auth.firebase.com" />
- And this line is in my index.html
- <meta http-equiv="Content-Security-Policy" content="connect-src *">
--
You received this message because you are subscribed to the Google Groups "Firebase + AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebase-angular+unsubscribe@googlegroups.com.
To post to this group, send email to firebase-angular@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/firebase-angular/d0036905-d608-453a-b367-59cd7f7899a8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.