added mongodb changes to auth