From 6aa048e3ad825ae0ea25ffea55cbbf20423fdd9c Mon Sep 17 00:00:00 2001 From: patriceac <48073125+patriceac@users.noreply.github.com> Date: Sun, 2 Apr 2023 02:04:03 -0700 Subject: [PATCH] Reset the LoRA dropdown if not present in the task --- ui/media/js/dnd.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ui/media/js/dnd.js b/ui/media/js/dnd.js index 98c5e26a..6e78609c 100644 --- a/ui/media/js/dnd.js +++ b/ui/media/js/dnd.js @@ -340,7 +340,12 @@ function restoreTaskToUI(task, fieldsToSkip) { hypernetworkModelField.value = "" hypernetworkModelField.dispatchEvent(new Event("change")) } - + + if (!('use_lora_model' in task.reqBody)) { + loraModelField.value = "None" + loraModelField.dispatchEvent(new Event("change")) + } + // restore the original prompt if provided (e.g. use settings), fallback to prompt as needed (e.g. copy/paste or d&d) promptField.value = task.reqBody.original_prompt if (!('original_prompt' in task.reqBody)) {