i dont know if this will work

in other words, your code was wrong. so the code should be `mongodb = models.Course.connection;
mongodb = new mongodb.Connection(secrets.db);`????