Regular undefined collection callback's

Hey there,

as I’ve seen in many tutorials, it’s not unusual to define Collection instances in a global js (in my case jsx) file.

MyDocument = new Mongo.Collection(“myDocument”);

So the problem is, that almost always if I change a file, the “myDocument” object is undefined for the first 2 - 3 refresh pages and then abrupt available.

After I got the error message in Chrome (undefined), I can strangely retrieve Data (the same retrieve as in my Code) with Chrome by the Console.

For example: MyDocument.find() won’t work for the first 2-3 time’s by changing a file and then the browser refresh. If I use the Chrome Developer Console then it work’s fine.
After a few time’s hit F5 more then I get the correct result in my Page Project too.

Best regards