The documentation for using a mongo collection is as follows:
Chatrooms = new Mongo.Collection(“chatrooms”);
I just wonder that if that collection is only used within that server js file - would the following be better?
var Chatrooms = new Mongo.Collection(“chatrooms”);
My reasoning (but I could be totally wrong!) is that by using the var word you make the application more secure - the collection is only available in the one js file, and I also suspect it might be more memory efficient than having a global varable.