fixes #494

Fixed DAO.prototype.equals