From 1fa8e6ae507444a6f8757aa27ef0c0c42cc35836 Mon Sep 17 00:00:00 2001 From: Chuck Date: Mon, 5 Jan 2026 14:17:43 -0500 Subject: [PATCH] Move array-of-objects functions outside IIFE to make them globally available The functions were inside the IIFE scope, making them inaccessible from inline event handlers. Moving them outside the IIFE ensures they're available on window when the script loads. --- web_interface/static/v3/plugins_manager.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/web_interface/static/v3/plugins_manager.js b/web_interface/static/v3/plugins_manager.js index fcaa0859..5f73db7b 100644 --- a/web_interface/static/v3/plugins_manager.js +++ b/web_interface/static/v3/plugins_manager.js @@ -3437,11 +3437,6 @@ window.updateKeyValuePairData = function(fieldId, fullKey) { hiddenInput.value = JSON.stringify(pairs); }; - -// Functions to handle array-of-objects -// Define these at the top level (outside any IIFE) to ensure they're always available -if (typeof window !== 'undefined') { - window.addArrayObjectItem = function(fieldId, fullKey, maxItems) { const itemsContainer = document.getElementById(fieldId + '_items'); const hiddenInput = document.getElementById(fieldId + '_data'); if (!itemsContainer || !hiddenInput) return;