Find Meteor collection with two different fields

I do my happy dace every time I work something out in Meteor that I couldnt find online. Trying to create a function in a helper that true or false, by searching a collection in Meteor with more than one field. Simply put a coma after the first field. Boom.

connected: function() 
{
return collection.findOne({userA:Meteor.user().username,UserB:this.user.username});
}

Leave a Reply