refactor: simplify `connect`, reuse a set for error event names
refactor: simplify `connect`, reuse a set for error event names

mongodb/node-mongodb-native,mongodb/node-mongodb-native,mongodb/node-mongodb-native,mongodb/node-mongodb-native