mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2024-12-12 09:26:33 +01:00
Fix local variable name
This commit is contained in:
parent
3812e3bdcb
commit
5b65448a70
@ -126,11 +126,11 @@ function selectSystemPromptCallback(args, name) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const quiet = isTrueBoolean(args?.quiet);
|
const quiet = isTrueBoolean(args?.quiet);
|
||||||
const instructNames = system_prompts.map(preset => preset.name);
|
const systemPromptNames = system_prompts.map(preset => preset.name);
|
||||||
let foundName = instructNames.find(x => x.toLowerCase() === name.toLowerCase());
|
let foundName = systemPromptNames.find(x => x.toLowerCase() === name.toLowerCase());
|
||||||
|
|
||||||
if (!foundName) {
|
if (!foundName) {
|
||||||
const fuse = new Fuse(instructNames);
|
const fuse = new Fuse(systemPromptNames);
|
||||||
const result = fuse.search(name);
|
const result = fuse.search(name);
|
||||||
|
|
||||||
if (result.length === 0) {
|
if (result.length === 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user