🔄 refactor: Consolidate Ask/Edit Controllers (#1365)

* refactor(Ask/Edit): consolidate ask/edit controllers between the main modules and openAI controllers to reduce repetition of code and increase reusability

* fix(winston/logger): circular dependency issue

* fix(config/scripts): fix script imports

* refactor(indexSync): make not configured message an info log message

* chore: create a rollup script for api/server/index.js to check circular dependencies

* chore: bump @keyv/redis
This commit is contained in:
Danny Avila 2023-12-15 15:47:40 -05:00 committed by GitHub
parent 0958db3825
commit 509b1e5c63
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 299 additions and 368 deletions

View file

@ -65,6 +65,8 @@ async function indexSync(req, res, next) {
logger.error('[indexSync] Trouble creating indices, try restarting the server.', err);
}
}, 750);
} else if (err.message.includes('Meilisearch not configured')) {
logger.info('[indexSync] Meilisearch not configured, search will be disabled.');
} else {
logger.error('[indexSync] error', err);
// res.status(500).json({ error: 'Server error' });