mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2026-02-01 05:11:19 -08:00
fix prompts containing special characters
This commit is contained in:
parent
2852fd6a76
commit
50aa168627
2 changed files with 39 additions and 32 deletions
|
|
@ -1429,7 +1429,13 @@ function extraNetworksControlRefreshOnClick(event) {
|
|||
}, EXTRA_NETWORKS_REFRESH_INTERNAL_DEBOUNCE_TIMEOUT_MS);
|
||||
}
|
||||
|
||||
function parsePrompt(input) {
|
||||
return input !== undefined ? JSON.parse(input) : input;
|
||||
}
|
||||
|
||||
function extraNetworksSelectModel({tab, prompt, neg_prompt, allow_neg, checkpoint_name}) {
|
||||
prompt = parsePrompt(prompt);
|
||||
neg_prompt = parsePrompt(neg_prompt);
|
||||
if (checkpoint_name) {
|
||||
selectCheckpoint(checkpoint_name);
|
||||
} else if (neg_prompt) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue