Fixed mongoose error logging