Trigger82 commited on
Commit
ddbaf47
·
verified ·
1 Parent(s): 59fb5d1

Update server.js

Browse files
Files changed (1) hide show
  1. server.js +1 -1
server.js CHANGED
@@ -27,7 +27,7 @@ async function connectDB() {
27
  // Initialize collections
28
  const collections = ['users', 'bots', 'sessions'];
29
  for (const colName of collections) {
30
- if (!(await db.listCollections({ name: colName }).hasNext()) {
31
  await db.createCollection(colName);
32
  console.log(`Created collection: ${colName}`);
33
  }
 
27
  // Initialize collections
28
  const collections = ['users', 'bots', 'sessions'];
29
  for (const colName of collections) {
30
+ if (!(await db.listCollections({ name: colName }).hasNext())) {
31
  await db.createCollection(colName);
32
  console.log(`Created collection: ${colName}`);
33
  }