Search code examples
angularjsmongodbmeteor

Why does Meteor/MongoDB change data when running this sample application?


I am trying to work through the sample application found at Angular Meteor tutorial.

I am running Mac OS X v10.10 (Yosemite) and using WebStorm 10 as the IDE. It is Meteor 1.2.1.

If I go into the command line and type 'meteor mongo', it brings me to the MongoDB command line.

If I type,

db.tasks.insert({"text" : "A new party", "description" : "From the mongo console!" })

and then type db.tasks.find(), I get back the object as expect.

{ "_id" : ObjectId("563c1a48d880b1f80bdb1fa2"), "text" : "A new party", "description" : "From the mongo console!" }

If I think simply run the example as shown in link, the data strangely changes to

{ "_id" : ObjectId("563c1a48d880b1f80bdb1fa2")}

and nothing else. This is simply by loading the page. No creation, no edit, nothing.

And then any ensuing attempt to insert more data doesn't even work the first time...it will also show some form of the above.

What am I missing?


Solution

  • The answer I found through the angularMeteor help form:

    The solution to fix your MongoDB from weirdly having data changed just by loading the page is to do the following:

    meteor remove angular
    meteor add angular@=1.0.6
    meteor reset