def connect_mongo(): client = MongoClient(settings.MONGO_HOST, settings.MONGO_PORT) return client[settings.MONGO_DATABASE]