mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-18 09:20:15 +01:00
🔧 fix: Remove Unique Index from Actions Model and Initialize Empty Actions for Deletion (#2118)
This commit is contained in:
parent
a8cdd3460c
commit
89f6b35e6c
2 changed files with 1 additions and 2 deletions
|
|
@ -45,7 +45,6 @@ const actionSchema = new Schema({
|
||||||
auth: AuthSchema,
|
auth: AuthSchema,
|
||||||
domain: {
|
domain: {
|
||||||
type: String,
|
type: String,
|
||||||
unique: true,
|
|
||||||
required: true,
|
required: true,
|
||||||
},
|
},
|
||||||
// json_schema: Schema.Types.Mixed,
|
// json_schema: Schema.Types.Mixed,
|
||||||
|
|
|
||||||
|
|
@ -162,7 +162,7 @@ router.delete('/:assistant_id/:action_id', async (req, res) => {
|
||||||
/** @type {[AssistantDocument, Assistant]} */
|
/** @type {[AssistantDocument, Assistant]} */
|
||||||
const [assistant_data, assistant] = await Promise.all(initialPromises);
|
const [assistant_data, assistant] = await Promise.all(initialPromises);
|
||||||
|
|
||||||
const { actions } = assistant_data ?? {};
|
const { actions = [] } = assistant_data ?? {};
|
||||||
const { tools = [] } = assistant ?? {};
|
const { tools = [] } = assistant ?? {};
|
||||||
|
|
||||||
let domain = '';
|
let domain = '';
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue