Meteor.user()
, when logged in, does not work in Firefox 43.0.4, only works in Chrome:
Foo = React.createClass({
getInitialState() {
var u = Meteor.user();
console.log(u); // undefined in Firefox but works in Chrome.
return{name: ''}
}
...
});
Server:
Meteor.publish(null, function () {
if (this.userId) {
return Meteor.users.find({_id: this.userId},
{fields: {'regtype': 1, 'profile': 1}});
} else {
this.ready();
}
});
Am I doing something wrong?