mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-29 06:38:50 +01:00
feat: utitlize lean queries, remove migration script, index createdAt timestamps (#698)
* feat(mongoDb): utitlize lean queries and index createdAt timestamps for cosmosDB support * fix: remove unnecessary lean() method from deleteMany calls * fix: remove unnecessary lean() method from deleteMany calls * fix: remove lean() from queries that need hydration * chore(migrateDb.js): remove unused migration script fix(Preset.js): return lean documents when retrieving presets refactor(index.js): remove migration script from server initialization refactor(convos.js): remove toObject() when sending conversation object refactor(presets.js): remove toObject() when sending presets object
This commit is contained in:
parent
2f7658e39f
commit
19af2b06ce
13 changed files with 34 additions and 160 deletions
|
|
@ -1,7 +1,6 @@
|
|||
const express = require('express');
|
||||
const session = require('express-session');
|
||||
const connectDb = require('../lib/db/connectDb');
|
||||
const migrateDb = require('../lib/db/migrateDb');
|
||||
const indexSync = require('../lib/db/indexSync');
|
||||
const path = require('path');
|
||||
const cors = require('cors');
|
||||
|
|
@ -28,7 +27,6 @@ config.validate(); // Validate the config
|
|||
(async () => {
|
||||
await connectDb();
|
||||
console.log('Connected to MongoDB');
|
||||
await migrateDb();
|
||||
await indexSync();
|
||||
|
||||
const app = express();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue