пофиксил отправку запросов для превью vMix
This commit is contained in:
@@ -1192,7 +1192,7 @@
|
||||
if (!inputName) return;
|
||||
|
||||
try {
|
||||
await fetch("/api/vmix/publish-command", {
|
||||
const response = await fetch("/api/vmix/publish-command", {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
@@ -1212,16 +1212,20 @@
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
if (!response.ok) {
|
||||
console.error("Ошибка отправки команды в vMix:", response.status);
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("Не удалось отправить команду в vMix:", error);
|
||||
}
|
||||
}
|
||||
|
||||
document.addEventListener("click", function (event) {
|
||||
const link = event.target.closest(".tab-link[data-vmix-preview-input]");
|
||||
const link = event.target.closest(".tab-link[data-vmix-title]");
|
||||
if (!link) return;
|
||||
|
||||
const inputName = link.dataset.vmixPreviewInput;
|
||||
const inputName = link.dataset.vmixTitle;
|
||||
sendVmixPreviewInput(inputName);
|
||||
});
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user