Fixed to code to make it work with prototype based mongodb-core
Fixes for making auth replset test pass
Changed server to use prototype