Replaced connecting to the mongodb from app.js to db.js.
Implemented finding all documents via Document model in index.