before mongo refactor