Mongo related fixes
More mongo fixes
Merge pull request #412 from mposolda/master

Mongo related fixes