Fix slash command params loading
Existing slash commands expect an object named "params" so mapping to "options" here caused params to be undefined within the run scope. I renamed from 'm' to 's' just to avoid potential confusion with the model property mapping above.
This commit is contained in:
parent
1cb0455f6e
commit
faabd384a1
2 changed files with 6 additions and 5 deletions
|
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"tabWidth": 2,
|
||||
"useTabs": false
|
||||
"useTabs": false,
|
||||
"trailingComma": "all"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -334,10 +334,10 @@ function finalToBrowserConfig(
|
|||
})),
|
||||
systemMessage: final.systemMessage,
|
||||
completionOptions: final.completionOptions,
|
||||
slashCommands: final.slashCommands?.map((m) => ({
|
||||
name: m.name,
|
||||
description: m.description,
|
||||
options: m.params,
|
||||
slashCommands: final.slashCommands?.map((s) => ({
|
||||
name: s.name,
|
||||
description: s.description,
|
||||
params: s.params, //PZTODO: is this why params aren't referenced properly by slash commands?
|
||||
})),
|
||||
contextProviders: final.contextProviders?.map((c) => c.description),
|
||||
disableIndexing: final.disableIndexing,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue