mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Fix oobabooga's status parsing
This commit is contained in:
@@ -430,7 +430,8 @@ app.post("/getstatus", jsonParser, function (request, response_getstatus = respo
|
|||||||
var response = body.match(/gradio_config[ =]*(\{.*\});/)[1];
|
var response = body.match(/gradio_config[ =]*(\{.*\});/)[1];
|
||||||
if (!response)
|
if (!response)
|
||||||
throw "no_connection";
|
throw "no_connection";
|
||||||
data = { result: JSON.parse(response).components.filter((x) => x.props.label == "Model")[0].props.value };
|
let model = JSON.parse(response).components.filter((x) => x.props.label == "Model" && x.type == "dropdown")[0].props.value;
|
||||||
|
data = { result: model };
|
||||||
if (!data)
|
if (!data)
|
||||||
throw "no_connection";
|
throw "no_connection";
|
||||||
} catch {
|
} catch {
|
||||||
|
Reference in New Issue
Block a user