Quick fix to support mongoDB and oauth2