mirror of
https://github.com/Mintplex-Labs/anything-llm
synced 2026-04-25 17:15:37 +02:00
lint
This commit is contained in:
@@ -30,9 +30,9 @@ class FlowExecutor {
|
||||
|
||||
// Convert the variable value to string
|
||||
let value = this.variables[varName];
|
||||
if (value === null) return '';
|
||||
if (value === null) return "";
|
||||
|
||||
if (typeof value === 'object') {
|
||||
if (typeof value === "object") {
|
||||
try {
|
||||
value = JSON.stringify(value);
|
||||
} catch (e) {
|
||||
@@ -41,7 +41,7 @@ class FlowExecutor {
|
||||
}
|
||||
|
||||
// If this is a URL, encode the value
|
||||
if (obj.startsWith('http://') || obj.startsWith('https://')) {
|
||||
if (obj.startsWith("http://") || obj.startsWith("https://")) {
|
||||
return encodeURIComponent(value);
|
||||
}
|
||||
|
||||
|
||||
@@ -40,7 +40,9 @@ async function executeApiCall(config, context) {
|
||||
}
|
||||
|
||||
try {
|
||||
introspect(`Sending body to ${decodedUrl}: ${requestConfig?.body || "No body"}`);
|
||||
introspect(
|
||||
`Sending body to ${decodedUrl}: ${requestConfig?.body || "No body"}`
|
||||
);
|
||||
const response = await fetch(decodedUrl, requestConfig);
|
||||
if (!response.ok) {
|
||||
introspect(`Request failed with status ${response.status}`);
|
||||
|
||||
Reference in New Issue
Block a user